|
| 1 | +DESC sys.schema_tables_with_full_table_scans; |
| 2 | +Field Type Null Key Default Extra |
| 3 | +object_schema varchar(64) YES NULL |
| 4 | +object_name varchar(64) YES NULL |
| 5 | +rows_full_scanned bigint(20) unsigned NO NULL |
| 6 | +latency text YES NULL |
| 7 | +DESC sys.x$schema_tables_with_full_table_scans; |
| 8 | +Field Type Null Key Default Extra |
| 9 | +object_schema varchar(64) YES NULL |
| 10 | +object_name varchar(64) YES NULL |
| 11 | +rows_full_scanned bigint(20) unsigned NO NULL |
| 12 | +latency bigint(20) unsigned NO NULL |
| 13 | +CREATE DATABASE v_schema_tables_with_full_table_scans; |
| 14 | +CREATE TABLE v_schema_tables_with_full_table_scans.t (i BIGINT AUTO_INCREMENT PRIMARY KEY, j BIGINT) ENGINE = innodb; |
| 15 | +INSERT INTO v_schema_tables_with_full_table_scans.t (j) VALUES (1), (2), (3); |
| 16 | +INSERT INTO v_schema_tables_with_full_table_scans.t (j) (SELECT j*2 FROM v_schema_tables_with_full_table_scans.t); |
| 17 | +INSERT INTO v_schema_tables_with_full_table_scans.t (j) (SELECT j*2 FROM v_schema_tables_with_full_table_scans.t); |
| 18 | +INSERT INTO v_schema_tables_with_full_table_scans.t (j) (SELECT j*2 FROM v_schema_tables_with_full_table_scans.t); |
| 19 | +INSERT INTO v_schema_tables_with_full_table_scans.t (j) (SELECT j*2 FROM v_schema_tables_with_full_table_scans.t); |
| 20 | +INSERT INTO v_schema_tables_with_full_table_scans.t (j) (SELECT j*2 FROM v_schema_tables_with_full_table_scans.t); |
| 21 | +INSERT INTO v_schema_tables_with_full_table_scans.t (j) (SELECT j*2 FROM v_schema_tables_with_full_table_scans.t); |
| 22 | +INSERT INTO v_schema_tables_with_full_table_scans.t (j) (SELECT j*2 FROM v_schema_tables_with_full_table_scans.t); |
| 23 | +INSERT INTO v_schema_tables_with_full_table_scans.t (j) (SELECT j*2 FROM v_schema_tables_with_full_table_scans.t); |
| 24 | +CALL sys.ps_truncate_all_tables(false); |
| 25 | +summary |
| 26 | +Truncated 44 tables |
| 27 | +SELECT * FROM v_schema_tables_with_full_table_scans.t WHERE j = 12; |
| 28 | +i j |
| 29 | +12 12 |
| 30 | +19 12 |
| 31 | +22 12 |
| 32 | +34 12 |
| 33 | +37 12 |
| 34 | +43 12 |
| 35 | +65 12 |
| 36 | +68 12 |
| 37 | +74 12 |
| 38 | +86 12 |
| 39 | +128 12 |
| 40 | +131 12 |
| 41 | +137 12 |
| 42 | +149 12 |
| 43 | +173 12 |
| 44 | +255 12 |
| 45 | +258 12 |
| 46 | +264 12 |
| 47 | +276 12 |
| 48 | +300 12 |
| 49 | +348 12 |
| 50 | +510 12 |
| 51 | +513 12 |
| 52 | +519 12 |
| 53 | +531 12 |
| 54 | +555 12 |
| 55 | +603 12 |
| 56 | +699 12 |
| 57 | +SELECT object_schema, object_name, rows_full_scanned FROM sys.schema_tables_with_full_table_scans; |
| 58 | +object_schema object_name rows_full_scanned |
| 59 | +v_schema_tables_with_full_table_scans t 768 |
| 60 | +SELECT object_schema, object_name, rows_full_scanned FROM sys.x$schema_tables_with_full_table_scans; |
| 61 | +object_schema object_name rows_full_scanned |
| 62 | +v_schema_tables_with_full_table_scans t 768 |
| 63 | +DROP DATABASE v_schema_tables_with_full_table_scans; |
0 commit comments