first commit

This commit is contained in:
Sandro Fuetsch Titan
2026-05-26 19:23:46 +02:00
commit 7a46ef3759
24 changed files with 636 additions and 0 deletions
Binary file not shown.
+53
View File
@@ -0,0 +1,53 @@
queries_maria = {
"no_index": {
"query_1": """
ANALYZE SELECT name, title
FROM Auth IGNORE INDEX (idx_auth_pubid), Publ IGNORE INDEX(idx_publ_pubid)
WHERE Auth.pubID = Publ.pubID;
""",
"query_2": """
ANALYZE SELECT title
FROM Auth IGNORE INDEX (idx_auth_pubid), Publ IGNORE INDEX(idx_publ_pubid)
WHERE Auth.pubID = Publ.pubID AND Auth.name = 'Divesh Srivastava';
""",
},
"with_index": {
"query_1": """
ANALYZE SELECT name, title
FROM Auth, Publ
WHERE Auth.pubID = Publ.pubID;
""",
"query_2": """
ANALYZE SELECT title
FROM Auth, Publ
WHERE Auth.pubID = Publ.pubID AND Auth.name = 'Divesh Srivastava';
""",
},
}
queries_postgres = {
"no_index": {
"query_1": """
EXPLAIN ANALYZE SELECT name, title
FROM Auth, Publ
WHERE Auth.pubID = Publ.pubID;
""",
"query_2": """
EXPLAIN ANALYZE SELECT title
FROM Auth, Publ
WHERE Auth.pubID = Publ.pubID AND Auth.name = 'Divesh Srivastava';
""",
},
"with_index": {
"query_1": """
EXPLAIN ANALYZE SELECT name, title
FROM Auth, Publ
WHERE Auth.pubID = Publ.pubID;
""",
"query_2": """
EXPLAIN ANALYZE SELECT title
FROM Auth, Publ
WHERE Auth.pubID = Publ.pubID AND Auth.name = 'Divesh Srivastava';
""",
},
}
+10
View File
@@ -0,0 +1,10 @@
resolve = {
"postgresql": {
"disable": ["SET enable_nestloop = off", "SET enable_mergejoin = off"],
"reset": ["RESET enable_nestloop", "RESET enable_mergejoin"],
},
"mariadb": {
"disable": ["SET optimizer_switch='join_cache_hashed=on'", "SET join_cache_level=8"],
"reset": ["SET optimizer_switch=DEFAULT", "SET join_cache_level=DEFAULT"],
},
}
+11
View File
@@ -0,0 +1,11 @@
# nestedLoopResolver.py
resolve = {
"postgresql": {
"disable": ["SET enable_hashjoin = off", "SET enable_mergejoin = off"],
"reset": ["RESET enable_hashjoin", "RESET enable_mergejoin"],
},
"mariadb": {
"disable": ["SET optimizer_switch='block_nested_loop=off'"],
"reset": ["SET optimizer_switch=DEFAULT"],
},
}
+7
View File
@@ -0,0 +1,7 @@
# sortMergeResolver.py
resolve = {
"postgresql": {
"disable": ["SET enable_hashjoin = off", "SET enable_nestloop = off"],
"reset": ["RESET enable_hashjoin", "RESET enable_nestloop"],
},
}