Skip to content

Commit 20906ae

Browse files
committed
Remove CREATE_TABLE column
1 parent 2c7e39b commit 20906ae

File tree

2 files changed

+3
-10
lines changed

2 files changed

+3
-10
lines changed

tests/WP_SQLite_Metadata_Tests.php

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -84,13 +84,6 @@ public function testInformationSchemaTables() {
8484
'ENGINE' => 'InnoDB',
8585
'ROW_FORMAT' => 'Dynamic',
8686
'TABLE_COLLATION' => 'utf8mb4_general_ci',
87-
'TABLE_COMMENT' => '',
88-
'CREATE_TABLE' => 'CREATE TABLE "wp_options"(
89-
"option_id" integer PRIMARY KEY AUTOINCREMENT NOT NULL,
90-
"option_name" text NOT NULL DEFAULT \'\' COLLATE NOCASE,
91-
"option_value" text NOT NULL COLLATE NOCASE,
92-
"autoload" text NOT NULL DEFAULT \'yes\' COLLATE NOCASE
93-
)',
9487
'AUTO_INCREMENT' => null,
9588
'CREATE_TIME' => null,
9689
'UPDATE_TIME' => null,
@@ -104,6 +97,7 @@ public function testInformationSchemaTables() {
10497
'CHECKSUM' => null,
10598
'CREATE_OPTIONS' => '',
10699
'VERSION' => '10',
100+
'TABLE_COMMENT' => '',
107101
),
108102
(array) $result[0]
109103
);

wp-includes/sqlite/class-wp-sqlite-translator.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1521,6 +1521,7 @@ private function execute_select() {
15211521
ELSE type
15221522
END as TABLE_TYPE,
15231523
'InnoDB' as ENGINE,
1524+
10 as VERSION,
15241525
'Dynamic' as ROW_FORMAT,
15251526
0 as TABLE_ROWS,
15261527
0 as AVG_ROW_LENGTH,
@@ -1535,9 +1536,7 @@ private function execute_select() {
15351536
'utf8mb4_general_ci' as TABLE_COLLATION,
15361537
NULL as CHECKSUM,
15371538
'' as CREATE_OPTIONS,
1538-
'' as TABLE_COMMENT,
1539-
10 as VERSION,
1540-
sql as CREATE_TABLE
1539+
'' as TABLE_COMMENT
15411540
FROM sqlite_master
15421541
WHERE type IN ('table', 'view'))",
15431542
$updated_query

0 commit comments

Comments
 (0)