diff --git a/app/Database/Migrations/2020-06-05-180000_add_soundbites.php b/app/Database/Migrations/2020-06-05-180000_add_soundbites.php index cf20ee1d..90573d51 100644 --- a/app/Database/Migrations/2020-06-05-180000_add_soundbites.php +++ b/app/Database/Migrations/2020-06-05-180000_add_soundbites.php @@ -34,10 +34,12 @@ class AddSoundbites extends Migration ], 'start_time' => [ 'type' => 'DECIMAL(8,3)', + 'unsigned' => true, ], 'duration' => [ // soundbite duration cannot be higher than 9999,999 seconds ~ 2.77 hours 'type' => 'DECIMAL(7,3)', + 'unsigned' => true, ], 'label' => [ 'type' => 'VARCHAR', diff --git a/app/Libraries/Analytics/Database/Migrations/2017-12-01-160000_add_analytics_podcasts_by_region.php b/app/Libraries/Analytics/Database/Migrations/2017-12-01-160000_add_analytics_podcasts_by_region.php index 57ee57b3..39d31492 100644 --- a/app/Libraries/Analytics/Database/Migrations/2017-12-01-160000_add_analytics_podcasts_by_region.php +++ b/app/Libraries/Analytics/Database/Migrations/2017-12-01-160000_add_analytics_podcasts_by_region.php @@ -37,11 +37,11 @@ class AddAnalyticsPodcastsByRegion extends Migration 'comment' => 'ISO 3166-2 code.', ], 'latitude' => [ - 'type' => 'DECIMAL', + 'type' => 'DECIMAL(8,6)', 'null' => true, ], 'longitude' => [ - 'type' => 'DECIMAL', + 'type' => 'DECIMAL(9,6)', 'null' => true, ], 'hits' => [ diff --git a/app/Libraries/Analytics/Database/Migrations/2017-12-01-210000_add_analytics_podcasts_procedure.php b/app/Libraries/Analytics/Database/Migrations/2017-12-01-210000_add_analytics_podcasts_procedure.php index b04b4e08..03c5fae4 100644 --- a/app/Libraries/Analytics/Database/Migrations/2017-12-01-210000_add_analytics_podcasts_procedure.php +++ b/app/Libraries/Analytics/Database/Migrations/2017-12-01-210000_add_analytics_podcasts_procedure.php @@ -26,14 +26,14 @@ class AddAnalyticsPodcastsProcedure extends Migration CREATE PROCEDURE `{$prefix}analytics_podcasts` ( IN `p_podcast_id` INT UNSIGNED, IN `p_episode_id` INT UNSIGNED, - IN `p_country_code` VARCHAR(3) CHARSET utf8mb4, - IN `p_region_code` VARCHAR(3) CHARSET utf8mb4, - IN `p_latitude` DECIMAL, - IN `p_longitude` DECIMAL, - IN `p_service` VARCHAR(128) CHARSET utf8mb4, - IN `p_app` VARCHAR(128) CHARSET utf8mb4, - IN `p_device` VARCHAR(32) CHARSET utf8mb4, - IN `p_os` VARCHAR(32) CHARSET utf8mb4, + IN `p_country_code` VARCHAR(3), + IN `p_region_code` VARCHAR(3), + IN `p_latitude` DECIMAL(8,6), + IN `p_longitude` DECIMAL(9,6), + IN `p_service` VARCHAR(128), + IN `p_app` VARCHAR(128), + IN `p_device` VARCHAR(32), + IN `p_os` VARCHAR(32), IN `p_bot` TINYINT(1) UNSIGNED, IN `p_filesize` INT UNSIGNED, IN `p_duration` INT UNSIGNED, diff --git a/app/Libraries/Analytics/Database/Migrations/2017-12-01-210000_add_analytics_unknown_useragents_procedure.php b/app/Libraries/Analytics/Database/Migrations/2017-12-01-210000_add_analytics_unknown_useragents_procedure.php index 918fa960..e7a0f9b0 100644 --- a/app/Libraries/Analytics/Database/Migrations/2017-12-01-210000_add_analytics_unknown_useragents_procedure.php +++ b/app/Libraries/Analytics/Database/Migrations/2017-12-01-210000_add_analytics_unknown_useragents_procedure.php @@ -22,7 +22,7 @@ class AddAnalyticsUnknownUseragentsProcedure extends Migration // Example: CALL analytics_unknown_useragents('Podcasts/1430.46 CFNetwork/1125.2 Darwin/19.4.0'); $procedureName = $this->db->prefixTable('analytics_unknown_useragents'); $createQuery = <<db->prefixTable('analytics_website'); $createQuery = <<