Skip to content

Instantly share code, notes, and snippets.

@spetrunia
Created March 19, 2024 08:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save spetrunia/a3ea8bb93c2b901d3fb5253458e80a97 to your computer and use it in GitHub Desktop.
Save spetrunia/a3ea8bb93c2b901d3fb5253458e80a97 to your computer and use it in GitHub Desktop.
# Time: 240319 11:13:38
# User@Host: root[root] @ localhost []
# Thread_id: 3 Schema: test QC_hit: No
# Query_time: 0.358257 Lock_time: 0.000121 Rows_sent: 1 Rows_examined: 18501
# Rows_affected: 0 Bytes_sent: 66
# Pages_accessed: 20020 Pages_read: 0 Pages_updated: 0 Old_rows_read: 0
# Pages_read_time: 0.0000 Engine_time: 338.2396
# Full_scan: Yes Full_join: No Tmp_table: No Tmp_table_on_disk: No
# Filesort: No Filesort_on_disk: No Merge_passes: 0 Priority_queue: No
#
# explain: id select_type table type possible_keys key key_len ref rows r_rows filtered r_filtered Extra
# explain: 1 SIMPLE A index NULL a 5 NULL 10157 10000.00 100.00 100.00 Using index
# explain: 1 SIMPLE B ref b b 5 func 923 0.85 100.00 100.00 Using where; Using index
#
SET timestamp=1710836018;
select count(*) from t1 A, t1 B where B.b=A.a+1;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment