Advertisement
jaideep06

Table creation

Jan 13th, 2023
1,350
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MySQL 0.84 KB | None | 0 0
  1. CREATE TABLE `wp_rank_math_analytics_gsc` (
  2.   `id` BIGINT(20) UNSIGNED NOT NULL,
  3.   `created` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP() ON UPDATE CURRENT_TIMESTAMP(),
  4.   `query` VARCHAR(1000) COLLATE utf8mb4_unicode_ci NOT NULL,
  5.   `page` VARCHAR(500) COLLATE utf8mb4_unicode_ci NOT NULL,
  6.   `clicks` mediumint(6) NOT NULL,
  7.   `impressions` mediumint(6) NOT NULL,
  8.   `position` DOUBLE NOT NULL,
  9.   `ctr` DOUBLE NOT NULL
  10. ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC;
  11.  
  12. ALTER TABLE `wp_rank_math_analytics_gsc`
  13.   ADD PRIMARY KEY (`id`),
  14.   ADD KEY `analytics_query` (`query`),
  15.   ADD KEY `analytics_page` (`page`),
  16.   ADD KEY `clicks` (`clicks`),
  17.   ADD KEY `position` (`position`);
  18.  
  19. ALTER TABLE `wp_rank_math_analytics_gsc`
  20.   MODIFY `id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=1;
  21. COMMIT;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement