Debian Codegraph @

mysql-test/suite/funcs_1/r/is_tables_embedded.result

raw
1 SHOW TABLES FROM information_schema LIKE 'TABLES';
2 Tables_in_information_schema (TABLES)
3 TABLES
4 #######################################################################
5 # Testcase 3.2.1.1: INFORMATION_SCHEMA tables can be queried via SELECT
6 #######################################################################
7 DROP VIEW IF EXISTS test.v1;
8 DROP PROCEDURE IF EXISTS test.p1;
9 DROP FUNCTION IF EXISTS test.f1;
10 CREATE VIEW test.v1 AS SELECT * FROM information_schema.TABLES;
11 CREATE PROCEDURE test.p1() SELECT * FROM information_schema.TABLES;
12 CREATE FUNCTION test.f1() returns BIGINT
13 BEGIN
14 DECLARE counter BIGINT DEFAULT NULL;
15 SELECT COUNT(*) INTO counter FROM information_schema.TABLES;
16 RETURN counter;
17 END//
18 # Attention: The printing of the next result sets is disabled.
19 SELECT * FROM information_schema.TABLES;
20 SELECT * FROM test.v1;
21 CALL test.p1;
22 SELECT test.f1();
23 DROP VIEW test.v1;
24 DROP PROCEDURE test.p1;
25 DROP FUNCTION test.f1;
26 #########################################################################
27 # Testcase 3.2.12.1: INFORMATION_SCHEMA.TABLES layout
28 #########################################################################
29 DESCRIBE information_schema.TABLES;
30 Field Type Null Key Default Extra
31 TABLE_CATALOG varchar(512) NO NULL
32 TABLE_SCHEMA varchar(64) NO NULL
33 TABLE_NAME varchar(64) NO NULL
34 TABLE_TYPE varchar(64) NO NULL
35 ENGINE varchar(64) YES NULL
36 VERSION bigint(21) unsigned YES NULL
37 ROW_FORMAT varchar(10) YES NULL
38 TABLE_ROWS bigint(21) unsigned YES NULL
39 AVG_ROW_LENGTH bigint(21) unsigned YES NULL
40 DATA_LENGTH bigint(21) unsigned YES NULL
41 MAX_DATA_LENGTH bigint(21) unsigned YES NULL
42 INDEX_LENGTH bigint(21) unsigned YES NULL
43 DATA_FREE bigint(21) unsigned YES NULL
44 AUTO_INCREMENT bigint(21) unsigned YES NULL
45 CREATE_TIME datetime YES NULL
46 UPDATE_TIME datetime YES NULL
47 CHECK_TIME datetime YES NULL
48 TABLE_COLLATION varchar(64) YES NULL
49 CHECKSUM bigint(21) unsigned YES NULL
50 CREATE_OPTIONS varchar(2048) YES NULL
51 TABLE_COMMENT varchar(2048) NO NULL
52 MAX_INDEX_LENGTH bigint(21) unsigned YES NULL
53 TEMPORARY varchar(1) YES NULL
54 SHOW CREATE TABLE information_schema.TABLES;
55 Table Create Table
56 TABLES CREATE TEMPORARY TABLE `TABLES` (
57 `TABLE_CATALOG` varchar(512) NOT NULL,
58 `TABLE_SCHEMA` varchar(64) NOT NULL,
59 `TABLE_NAME` varchar(64) NOT NULL,
60 `TABLE_TYPE` varchar(64) NOT NULL,
61 `ENGINE` varchar(64),
62 `VERSION` bigint(21) unsigned,
63 `ROW_FORMAT` varchar(10),
64 `TABLE_ROWS` bigint(21) unsigned,
65 `AVG_ROW_LENGTH` bigint(21) unsigned,
66 `DATA_LENGTH` bigint(21) unsigned,
67 `MAX_DATA_LENGTH` bigint(21) unsigned,
68 `INDEX_LENGTH` bigint(21) unsigned,
69 `DATA_FREE` bigint(21) unsigned,
70 `AUTO_INCREMENT` bigint(21) unsigned,
71 `CREATE_TIME` datetime,
72 `UPDATE_TIME` datetime,
73 `CHECK_TIME` datetime,
74 `TABLE_COLLATION` varchar(64),
75 `CHECKSUM` bigint(21) unsigned,
76 `CREATE_OPTIONS` varchar(2048),
77 `TABLE_COMMENT` varchar(2048) NOT NULL,
78 `MAX_INDEX_LENGTH` bigint(21) unsigned,
79 `TEMPORARY` varchar(1)
80 ) ENGINE=MEMORY DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_general_ci
81 SHOW COLUMNS FROM information_schema.TABLES;
82 Field Type Null Key Default Extra
83 TABLE_CATALOG varchar(512) NO NULL
84 TABLE_SCHEMA varchar(64) NO NULL
85 TABLE_NAME varchar(64) NO NULL
86 TABLE_TYPE varchar(64) NO NULL
87 ENGINE varchar(64) YES NULL
88 VERSION bigint(21) unsigned YES NULL
89 ROW_FORMAT varchar(10) YES NULL
90 TABLE_ROWS bigint(21) unsigned YES NULL
91 AVG_ROW_LENGTH bigint(21) unsigned YES NULL
92 DATA_LENGTH bigint(21) unsigned YES NULL
93 MAX_DATA_LENGTH bigint(21) unsigned YES NULL
94 INDEX_LENGTH bigint(21) unsigned YES NULL
95 DATA_FREE bigint(21) unsigned YES NULL
96 AUTO_INCREMENT bigint(21) unsigned YES NULL
97 CREATE_TIME datetime YES NULL
98 UPDATE_TIME datetime YES NULL
99 CHECK_TIME datetime YES NULL
100 TABLE_COLLATION varchar(64) YES NULL
101 CHECKSUM bigint(21) unsigned YES NULL
102 CREATE_OPTIONS varchar(2048) YES NULL
103 TABLE_COMMENT varchar(2048) NO NULL
104 MAX_INDEX_LENGTH bigint(21) unsigned YES NULL
105 TEMPORARY varchar(1) YES NULL
106 SELECT table_catalog, table_schema, table_name
107 FROM information_schema.tables WHERE table_catalog IS NULL OR table_catalog <> 'def';
108 table_catalog table_schema table_name
109 ################################################################################
110 # Testcase 3.2.12.2 + 3.2.12.3: INFORMATION_SCHEMA.TABLES accessible information
111 ################################################################################
112 DROP DATABASE IF EXISTS db_datadict;
113 CREATE DATABASE db_datadict;
114 DROP USER 'testuser1'@'localhost';
115 CREATE USER 'testuser1'@'localhost';
116 GRANT CREATE, CREATE VIEW, INSERT, SELECT ON db_datadict.*
117 TO 'testuser1'@'localhost' WITH GRANT OPTION;
118 DROP USER 'testuser2'@'localhost';
119 CREATE USER 'testuser2'@'localhost';
120 DROP USER 'testuser3'@'localhost';
121 CREATE USER 'testuser3'@'localhost';
122 CREATE TABLE db_datadict.tb1 (f1 INT, f2 INT, f3 INT)
123 ENGINE = <engine_type>;
124 GRANT SELECT ON db_datadict.tb1 TO 'testuser1'@'localhost';
125 GRANT ALL ON db_datadict.tb1 TO 'testuser2'@'localhost' WITH GRANT OPTION;
126 connect testuser1, localhost, testuser1, , db_datadict;
127 CREATE TABLE tb2 (f1 DECIMAL)
128 ENGINE = <engine_type>;
129 CREATE TABLE tb3 (f1 VARCHAR(200))
130 ENGINE = <engine_type>;
131 GRANT SELECT ON db_datadict.tb3 to 'testuser3'@'localhost';
132 GRANT INSERT ON db_datadict.tb3 to 'testuser2'@'localhost';
133 CREATE VIEW v3 AS SELECT * FROM tb3;
134 GRANT SELECT ON db_datadict.v3 to 'testuser3'@'localhost';
135 SELECT * FROM information_schema.tables
136 WHERE table_schema = 'db_datadict' ORDER BY table_name;
137 TABLE_CATALOG TABLE_SCHEMA TABLE_NAME TABLE_TYPE ENGINE VERSION ROW_FORMAT TABLE_ROWS AVG_ROW_LENGTH DATA_LENGTH MAX_DATA_LENGTH INDEX_LENGTH DATA_FREE AUTO_INCREMENT CREATE_TIME UPDATE_TIME CHECK_TIME TABLE_COLLATION CHECKSUM CREATE_OPTIONS TABLE_COMMENT MAX_INDEX_LENGTH TEMPORARY
138 def db_datadict tb1 BASE TABLE #ENG# 10 #RF# 0 #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# utf8mb4_uca1400_ai_ci #CS# 0 N
139 def db_datadict tb2 BASE TABLE #ENG# 10 #RF# 0 #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# utf8mb4_uca1400_ai_ci #CS# 0 N
140 def db_datadict tb3 BASE TABLE #ENG# 10 #RF# 0 #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# utf8mb4_uca1400_ai_ci #CS# 0 N
141 def db_datadict v3 VIEW #ENG# NULL #RF# NULL #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# NULL #CS# NULL VIEW NULL NULL
142 SHOW TABLES FROM db_datadict;
143 Tables_in_db_datadict
144 tb1
145 tb2
146 tb3
147 v3
148 connect testuser2, localhost, testuser2, , db_datadict;
149 SELECT * FROM information_schema.tables
150 WHERE table_schema = 'db_datadict' ORDER BY table_name;
151 TABLE_CATALOG TABLE_SCHEMA TABLE_NAME TABLE_TYPE ENGINE VERSION ROW_FORMAT TABLE_ROWS AVG_ROW_LENGTH DATA_LENGTH MAX_DATA_LENGTH INDEX_LENGTH DATA_FREE AUTO_INCREMENT CREATE_TIME UPDATE_TIME CHECK_TIME TABLE_COLLATION CHECKSUM CREATE_OPTIONS TABLE_COMMENT MAX_INDEX_LENGTH TEMPORARY
152 def db_datadict tb1 BASE TABLE #ENG# 10 #RF# 0 #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# utf8mb4_uca1400_ai_ci #CS# 0 N
153 def db_datadict tb2 BASE TABLE #ENG# 10 #RF# 0 #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# utf8mb4_uca1400_ai_ci #CS# 0 N
154 def db_datadict tb3 BASE TABLE #ENG# 10 #RF# 0 #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# utf8mb4_uca1400_ai_ci #CS# 0 N
155 def db_datadict v3 VIEW #ENG# NULL #RF# NULL #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# NULL #CS# NULL VIEW NULL NULL
156 SHOW TABLES FROM db_datadict;
157 Tables_in_db_datadict
158 tb1
159 tb2
160 tb3
161 v3
162 connect testuser3, localhost, testuser3, , db_datadict;
163 SELECT * FROM information_schema.tables
164 WHERE table_schema = 'db_datadict' ORDER BY table_name;
165 TABLE_CATALOG TABLE_SCHEMA TABLE_NAME TABLE_TYPE ENGINE VERSION ROW_FORMAT TABLE_ROWS AVG_ROW_LENGTH DATA_LENGTH MAX_DATA_LENGTH INDEX_LENGTH DATA_FREE AUTO_INCREMENT CREATE_TIME UPDATE_TIME CHECK_TIME TABLE_COLLATION CHECKSUM CREATE_OPTIONS TABLE_COMMENT MAX_INDEX_LENGTH TEMPORARY
166 def db_datadict tb1 BASE TABLE #ENG# 10 #RF# 0 #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# utf8mb4_uca1400_ai_ci #CS# 0 N
167 def db_datadict tb2 BASE TABLE #ENG# 10 #RF# 0 #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# utf8mb4_uca1400_ai_ci #CS# 0 N
168 def db_datadict tb3 BASE TABLE #ENG# 10 #RF# 0 #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# utf8mb4_uca1400_ai_ci #CS# 0 N
169 def db_datadict v3 VIEW #ENG# NULL #RF# NULL #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# NULL #CS# NULL VIEW NULL NULL
170 SHOW TABLES FROM db_datadict;
171 Tables_in_db_datadict
172 tb1
173 tb2
174 tb3
175 v3
176 connection default;
177 SELECT * FROM information_schema.tables
178 WHERE table_schema = 'db_datadict' ORDER BY table_name;
179 TABLE_CATALOG TABLE_SCHEMA TABLE_NAME TABLE_TYPE ENGINE VERSION ROW_FORMAT TABLE_ROWS AVG_ROW_LENGTH DATA_LENGTH MAX_DATA_LENGTH INDEX_LENGTH DATA_FREE AUTO_INCREMENT CREATE_TIME UPDATE_TIME CHECK_TIME TABLE_COLLATION CHECKSUM CREATE_OPTIONS TABLE_COMMENT MAX_INDEX_LENGTH TEMPORARY
180 def db_datadict tb1 BASE TABLE #ENG# 10 #RF# 0 #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# utf8mb4_uca1400_ai_ci #CS# 0 N
181 def db_datadict tb2 BASE TABLE #ENG# 10 #RF# 0 #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# utf8mb4_uca1400_ai_ci #CS# 0 N
182 def db_datadict tb3 BASE TABLE #ENG# 10 #RF# 0 #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# utf8mb4_uca1400_ai_ci #CS# 0 N
183 def db_datadict v3 VIEW #ENG# NULL #RF# NULL #ARL# #DL# #MDL# #IL# #DF# NULL #CRT #UT# #CT# NULL #CS# NULL VIEW NULL NULL
184 SHOW TABLES FROM db_datadict;
185 Tables_in_db_datadict
186 tb1
187 tb2
188 tb3
189 v3
190 disconnect testuser1;
191 disconnect testuser2;
192 disconnect testuser3;
193 DROP USER 'testuser1'@'localhost';
194 DROP USER 'testuser2'@'localhost';
195 DROP USER 'testuser3'@'localhost';
196 DROP DATABASE db_datadict;
197 #########################################################################
198 # 3.2.1.13+3.2.1.14+3.2.1.15: INFORMATION_SCHEMA.TABLES modifications
199 #########################################################################
200 DROP TABLE IF EXISTS test.t1_my_table;
201 DROP DATABASE IF EXISTS db_datadict;
202 CREATE DATABASE db_datadict;
203 SELECT table_name FROM information_schema.tables
204 WHERE table_name LIKE 't1_my_table%';
205 table_name
206 CREATE TABLE test.t1_my_table (f1 BIGINT)
207 DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci
208 COMMENT = 'Initial Comment' ENGINE = <engine_type>;
209 SELECT * FROM information_schema.tables
210 WHERE table_name = 't1_my_table';
211 TABLE_CATALOG def
212 TABLE_SCHEMA test
213 TABLE_NAME t1_my_table
214 TABLE_TYPE BASE TABLE
215 ENGINE #ENG#
216 VERSION 10
217 ROW_FORMAT #RF#
218 TABLE_ROWS 0
219 AVG_ROW_LENGTH #ARL#
220 DATA_LENGTH #DL#
221 MAX_DATA_LENGTH #MDL#
222 INDEX_LENGTH #IL#
223 DATA_FREE #DF#
224 AUTO_INCREMENT NULL
225 CREATE_TIME #CRT
226 UPDATE_TIME #UT#
227 CHECK_TIME #CT#
228 TABLE_COLLATION latin1_swedish_ci
229 CHECKSUM #CS#
230 CREATE_OPTIONS
231 TABLE_COMMENT Initial Comment
232 MAX_INDEX_LENGTH 0
233 TEMPORARY N
234 SELECT table_name FROM information_schema.tables
235 WHERE table_name LIKE 't1_my_table%';
236 table_name
237 t1_my_table
238 RENAME TABLE test.t1_my_table TO test.t1_my_tablex;
239 SELECT table_name FROM information_schema.tables
240 WHERE table_name LIKE 't1_my_table%';
241 table_name
242 t1_my_tablex
243 SELECT table_schema,table_name FROM information_schema.tables
244 WHERE table_name = 't1_my_tablex';
245 table_schema table_name
246 test t1_my_tablex
247 RENAME TABLE test.t1_my_tablex TO db_datadict.t1_my_tablex;
248 SELECT table_schema,table_name FROM information_schema.tables
249 WHERE table_name = 't1_my_tablex';
250 table_schema table_name
251 db_datadict t1_my_tablex
252 SELECT table_name, engine FROM information_schema.tables
253 WHERE table_name = 't1_my_tablex';
254 table_name engine
255 t1_my_tablex <engine_type>
256 ALTER TABLE db_datadict.t1_my_tablex
257 ENGINE = <other_engine_type>;
258 SELECT table_name, engine FROM information_schema.tables
259 WHERE table_name = 't1_my_tablex';
260 table_name engine
261 t1_my_tablex <other_engine_type>
262 SELECT table_name, table_rows FROM information_schema.tables
263 WHERE table_name = 't1_my_tablex';
264 table_name table_rows
265 t1_my_tablex 0
266 INSERT INTO db_datadict.t1_my_tablex VALUES(1),(2);
267 SELECT table_name, table_rows FROM information_schema.tables
268 WHERE table_name = 't1_my_tablex';
269 table_name table_rows
270 t1_my_tablex 2
271 SELECT table_name, table_collation FROM information_schema.tables
272 WHERE table_name = 't1_my_tablex';
273 table_name table_collation
274 t1_my_tablex latin1_swedish_ci
275 ALTER TABLE db_datadict.t1_my_tablex DEFAULT CHARACTER SET utf8;
276 SELECT table_name, table_collation FROM information_schema.tables
277 WHERE table_name = 't1_my_tablex';
278 table_name table_collation
279 t1_my_tablex utf8mb3_uca1400_ai_ci
280 SELECT table_name, table_collation FROM information_schema.tables
281 WHERE table_name = 't1_my_tablex';
282 table_name table_collation
283 t1_my_tablex utf8mb3_uca1400_ai_ci
284 ALTER TABLE db_datadict.t1_my_tablex
285 DEFAULT CHARACTER SET latin1 COLLATE latin1_german1_ci;
286 SELECT table_name, table_collation FROM information_schema.tables
287 WHERE table_name = 't1_my_tablex';
288 table_name table_collation
289 t1_my_tablex latin1_german1_ci
290 SELECT table_name, TABLE_COMMENT FROM information_schema.tables
291 WHERE table_name = 't1_my_tablex';
292 table_name TABLE_COMMENT
293 t1_my_tablex Initial Comment
294 ALTER TABLE db_datadict.t1_my_tablex COMMENT 'Changed Comment';
295 SELECT table_name, TABLE_COMMENT FROM information_schema.tables
296 WHERE table_name = 't1_my_tablex';
297 table_name TABLE_COMMENT
298 t1_my_tablex Changed Comment
299 SELECT table_name, AUTO_INCREMENT FROM information_schema.tables
300 WHERE table_name = 't1_my_tablex';
301 table_name AUTO_INCREMENT
302 t1_my_tablex NULL
303 ALTER TABLE db_datadict.t1_my_tablex
304 ADD f2 BIGINT AUTO_INCREMENT, ADD PRIMARY KEY (f2);
305 SELECT table_name, AUTO_INCREMENT FROM information_schema.tables
306 WHERE table_name = 't1_my_tablex';
307 table_name AUTO_INCREMENT
308 t1_my_tablex 3
309 SELECT table_name, ROW_FORMAT FROM information_schema.tables
310 WHERE table_name = 't1_my_tablex';
311 table_name ROW_FORMAT
312 t1_my_tablex Fixed
313 ALTER TABLE db_datadict.t1_my_tablex ROW_FORMAT = dynamic;
314 SELECT table_name, ROW_FORMAT FROM information_schema.tables
315 WHERE table_name = 't1_my_tablex';
316 table_name ROW_FORMAT
317 t1_my_tablex Dynamic
318 SELECT table_name, checksum FROM information_schema.tables
319 WHERE table_name = 't1_my_tablex';
320 table_name checksum
321 t1_my_tablex NULL
322 ALTER TABLE db_datadict.t1_my_tablex CHECKSUM = 1;
323 SELECT table_name, checksum IS NOT NULL FROM information_schema.tables
324 WHERE table_name = 't1_my_tablex';
325 table_name checksum IS NOT NULL
326 t1_my_tablex 1
327 SELECT UPDATE_TIME, checksum INTO @UPDATE_TIME, @checksum
328 FROM information_schema.tables
329 WHERE table_name = 't1_my_tablex';
330 INSERT INTO db_datadict.t1_my_tablex SET f1 = 3;
331 FLUSH TABLES;
332 SELECT UPDATE_TIME > @UPDATE_TIME
333 AS "Is current UPDATE_TIME bigger than before last INSERT?"
334 FROM information_schema.tables
335 WHERE table_name = 't1_my_tablex';
336 Is current UPDATE_TIME bigger than before last INSERT?
337 1
338 SELECT checksum <> @checksum
339 AS "Is current CHECKSUM different than before last INSERT?"
340 FROM information_schema.tables
341 WHERE table_name = 't1_my_tablex';
342 Is current CHECKSUM different than before last INSERT?
343 1
344 SELECT CREATE_TIME INTO @CREATE_TIME FROM information_schema.tables
345 WHERE table_name = 't1_my_tablex';
346 SELECT table_name FROM information_schema.tables
347 WHERE table_name LIKE 't1_my_table%';
348 table_name
349 t1_my_tablex
350 DROP TABLE db_datadict.t1_my_tablex;
351 SELECT table_name FROM information_schema.tables
352 WHERE table_name LIKE 't1_my_table%';
353 table_name
354 CREATE TABLE test.t1_my_tablex (f1 BIGINT)
355 ENGINE = <other_engine_type>;
356 SELECT CREATE_TIME > @CREATE_TIME
357 AS "Is current CREATE_TIME bigger than for the old dropped table?"
358 FROM information_schema.tables
359 WHERE table_name = 't1_my_tablex';
360 Is current CREATE_TIME bigger than for the old dropped table?
361 1
362 DROP TABLE test.t1_my_tablex;
363 CREATE VIEW test.t1_my_tablex AS SELECT 1;
364 SELECT * FROM information_schema.tables
365 WHERE table_name = 't1_my_tablex';
366 TABLE_CATALOG def
367 TABLE_SCHEMA test
368 TABLE_NAME t1_my_tablex
369 TABLE_TYPE VIEW
370 ENGINE NULL
371 VERSION NULL
372 ROW_FORMAT NULL
373 TABLE_ROWS NULL
374 AVG_ROW_LENGTH NULL
375 DATA_LENGTH NULL
376 MAX_DATA_LENGTH NULL
377 INDEX_LENGTH NULL
378 DATA_FREE NULL
379 AUTO_INCREMENT NULL
380 CREATE_TIME NULL
381 UPDATE_TIME NULL
382 CHECK_TIME NULL
383 TABLE_COLLATION NULL
384 CHECKSUM NULL
385 CREATE_OPTIONS NULL
386 TABLE_COMMENT VIEW
387 MAX_INDEX_LENGTH NULL
388 TEMPORARY NULL
389 DROP VIEW test.t1_my_tablex;
390 SELECT table_name FROM information_schema.tables
391 WHERE table_name = 't1_my_tablex';
392 table_name
393 CREATE TEMPORARY TABLE test.t1_my_tablex
394 ENGINE = <other_engine_type>
395 AS SELECT 1;
396 SELECT table_name, table_type FROM information_schema.tables
397 WHERE table_name = 't1_my_tablex';
398 table_name t1_my_tablex
399 table_type TEMPORARY
400 DROP TEMPORARY TABLE test.t1_my_tablex;
401 CREATE TABLE db_datadict.t1_my_tablex
402 ENGINE = <engine_type> AS
403 SELECT 1;
404 SELECT table_name FROM information_schema.tables
405 WHERE table_name = 't1_my_tablex';
406 table_name
407 t1_my_tablex
408 DROP DATABASE db_datadict;
409 SELECT table_name FROM information_schema.tables
410 WHERE table_name = 't1_my_tablex';
411 table_name
412 ########################################################################
413 # Testcases 3.2.1.3-3.2.1.5 + 3.2.1.8-3.2.1.12: INSERT/UPDATE/DELETE and
414 # DDL on INFORMATION_SCHEMA tables are not supported
415 ########################################################################
416 DROP DATABASE IF EXISTS db_datadict;
417 CREATE DATABASE db_datadict;
418 CREATE TABLE db_datadict.t1 (f1 BIGINT)
419 ENGINE = <engine_type>;
420 INSERT INTO information_schema.tables
421 SELECT * FROM information_schema.tables;
422 ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema'
423 UPDATE information_schema.tables SET table_schema = 'test'
424 WHERE table_name = 't1';
425 Got one of the listed errors
426 DELETE FROM information_schema.tables WHERE table_name = 't1';
427 ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema'
428 TRUNCATE information_schema.tables;
429 ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema'
430 CREATE INDEX my_idx_on_tables ON information_schema.tables(table_schema);
431 ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema'
432 ALTER TABLE information_schema.tables DROP PRIMARY KEY;
433 ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema'
434 ALTER TABLE information_schema.tables ADD f1 INT;
435 ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema'
436 DROP TABLE information_schema.tables;
437 ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema'
438 ALTER TABLE information_schema.tables RENAME db_datadict.tables;
439 ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema'
440 ALTER TABLE information_schema.tables RENAME information_schema.xtables;
441 ERROR 42000: Access denied for user 'root'@'localhost' to database 'information_schema'
442 DROP DATABASE db_datadict;