Disjunction[edit]
Debug output SQLStore
ASK Query
[[Category:API]] OR[[Country::China]]
SQL Query
SELECT DISTINCT
t0.smw_id AS id,
t0.smw_title AS t,
t0.smw_namespace AS ns,
t0.smw_iw AS iw,
t0.smw_subobject AS so,
t0.smw_sortkey AS sortkey, t0.smw_sort
FROM
`smw_object_ids` AS t0
INNER JOIN
`t1` AS t1 ON t0.smw_id=t1.id
WHERE
t0.smw_iw!=':smw'
AND t0.smw_iw!=':smw-delete'
AND t0.smw_iw!=':smw-redi'
ORDER BY
t0.smw_sort ASC
LIMIT
55
OFFSET
0
t0.smw_id AS id,
t0.smw_title AS t,
t0.smw_namespace AS ns,
t0.smw_iw AS iw,
t0.smw_subobject AS so,
t0.smw_sortkey AS sortkey, t0.smw_sort
FROM
`smw_object_ids` AS t0
INNER JOIN
`t1` AS t1 ON t0.smw_id=t1.id
WHERE
t0.smw_iw!=':smw'
AND t0.smw_iw!=':smw-delete'
AND t0.smw_iw!=':smw-redi'
ORDER BY
t0.smw_sort ASC
LIMIT
55
OFFSET
0
SQL Explain
ID | select_type | table | type | possible_keys | key | key_len | ref | rows | filtered | Extra |
---|---|---|---|---|---|---|---|---|---|---|
1 | SIMPLE | t1 | ALL | PRIMARY | 42 | Using temporary; Using filesort | ||||
1 | SIMPLE | t0 | eq_ref | PRIMARY, smw_id, smw_iw, smw_iw_2 | PRIMARY | 4 | DB9907220070920.t1.id | 1 | Using where |
Auxilliary Tables
- Temporary table t1
INSERT IGNORE INTO `t1` SELECT DISTINCT t2.s_id FROM `smw_fpt_inst` AS t2 INNER JOIN `t3` AS t3 ON t2.o_id=t3.id
INSERT IGNORE INTO `t1` SELECT DISTINCT t4.s_id FROM `smw_di_wikipage` AS t4 WHERE t4.p_id='148394' AND t4.o_id='7236' - Temporary table t3
Recursively computed hierarchy for element(s) ('14629').
SELECT s_id FROM `smw_fpt_subc` WHERE o_id='14629' LIMIT 1
Query Metrics
Query-Size:3Query-Depth:1
Errors and Warnings
NoneNested disjunctions[edit]
Debug output SQLStore
ASK Query
[[Category:API]] OR[[Country::China]]OR[[Capital of::France]]OR[[Country::Germany]]
SQL Query
SELECT DISTINCT
t0.smw_id AS id,
t0.smw_title AS t,
t0.smw_namespace AS ns,
t0.smw_iw AS iw,
t0.smw_subobject AS so,
t0.smw_sortkey AS sortkey, t0.smw_sort
FROM
`smw_object_ids` AS t0
INNER JOIN
`t1` AS t1 ON t0.smw_id=t1.id
WHERE
t0.smw_iw!=':smw'
AND t0.smw_iw!=':smw-delete'
AND t0.smw_iw!=':smw-redi'
ORDER BY
t0.smw_sort ASC
LIMIT
55
OFFSET
0
t0.smw_id AS id,
t0.smw_title AS t,
t0.smw_namespace AS ns,
t0.smw_iw AS iw,
t0.smw_subobject AS so,
t0.smw_sortkey AS sortkey, t0.smw_sort
FROM
`smw_object_ids` AS t0
INNER JOIN
`t1` AS t1 ON t0.smw_id=t1.id
WHERE
t0.smw_iw!=':smw'
AND t0.smw_iw!=':smw-delete'
AND t0.smw_iw!=':smw-redi'
ORDER BY
t0.smw_sort ASC
LIMIT
55
OFFSET
0
SQL Explain
ID | select_type | table | type | possible_keys | key | key_len | ref | rows | filtered | Extra |
---|---|---|---|---|---|---|---|---|---|---|
1 | SIMPLE | t1 | ALL | PRIMARY | 66 | Using temporary; Using filesort | ||||
1 | SIMPLE | t0 | eq_ref | PRIMARY, smw_id, smw_iw, smw_iw_2 | PRIMARY | 4 | DB9907220070920.t1.id | 1 | Using where |
Auxilliary Tables
- Temporary table t1
INSERT IGNORE INTO `t1` SELECT DISTINCT t2.s_id FROM `smw_fpt_inst` AS t2 INNER JOIN `t3` AS t3 ON t2.o_id=t3.id
INSERT IGNORE INTO `t1` SELECT DISTINCT t4.s_id FROM `smw_di_wikipage` AS t4 WHERE t4.p_id='148394' AND t4.o_id='7236'
INSERT IGNORE INTO `t1` SELECT DISTINCT t7.s_id FROM `smw_di_wikipage` AS t7 WHERE t7.p_id='148243' AND t7.o_id='798'
INSERT IGNORE INTO `t1` SELECT DISTINCT t10.s_id FROM `smw_di_wikipage` AS t10 WHERE t10.p_id='148394' AND t10.o_id='779' - Temporary table t3
Recursively computed hierarchy for element(s) ('14629').
SELECT s_id FROM `smw_fpt_subc` WHERE o_id='14629' LIMIT 1
Query Metrics
Query-Size:7Query-Depth:1
Errors and Warnings
NoneDisjunctions in a conjunction[edit]
Debug output SQLStore
ASK Query
[[Category:API]] OR[[Country::China]]
[[Capital of::France]]OR[[Country::Germany]]
SQL Query
SELECT DISTINCT
t0.smw_id AS id,
t0.smw_title AS t,
t0.smw_namespace AS ns,
t0.smw_iw AS iw,
t0.smw_subobject AS so,
t0.smw_sortkey AS sortkey, t0.smw_sort
FROM
`smw_object_ids` AS t0
INNER JOIN
(`t8` AS t8
INNER JOIN
`t2` AS t2 ON t8.id=t2.id) ON t0.smw_id=t8.id
WHERE
t0.smw_iw!=':smw'
AND t0.smw_iw!=':smw-delete'
AND t0.smw_iw!=':smw-redi'
ORDER BY
t0.smw_sort ASC
LIMIT
55
OFFSET
0
t0.smw_id AS id,
t0.smw_title AS t,
t0.smw_namespace AS ns,
t0.smw_iw AS iw,
t0.smw_subobject AS so,
t0.smw_sortkey AS sortkey, t0.smw_sort
FROM
`smw_object_ids` AS t0
INNER JOIN
(`t8` AS t8
INNER JOIN
`t2` AS t2 ON t8.id=t2.id) ON t0.smw_id=t8.id
WHERE
t0.smw_iw!=':smw'
AND t0.smw_iw!=':smw-delete'
AND t0.smw_iw!=':smw-redi'
ORDER BY
t0.smw_sort ASC
LIMIT
55
OFFSET
0
SQL Explain
ID | select_type | table | type | possible_keys | key | key_len | ref | rows | filtered | Extra |
---|---|---|---|---|---|---|---|---|---|---|
1 | SIMPLE | t8 | ALL | PRIMARY | 24 | Using temporary; Using filesort | ||||
1 | SIMPLE | t2 | eq_ref | PRIMARY | PRIMARY | 4 | DB9907220070920.t8.id | 1 | ||
1 | SIMPLE | t0 | eq_ref | PRIMARY, smw_id, smw_iw, smw_iw_2 | PRIMARY | 4 | DB9907220070920.t8.id | 1 | Using where |
Auxilliary Tables
- Temporary table t8
INSERT IGNORE INTO `t8` SELECT DISTINCT t9.s_id FROM `smw_di_wikipage` AS t9 WHERE t9.p_id='148243' AND t9.o_id='798'
INSERT IGNORE INTO `t8` SELECT DISTINCT t12.s_id FROM `smw_di_wikipage` AS t12 WHERE t12.p_id='148394' AND t12.o_id='779' - Temporary table t2
INSERT IGNORE INTO `t2` SELECT DISTINCT t3.s_id FROM `smw_fpt_inst` AS t3 INNER JOIN `t4` AS t4 ON t3.o_id=t4.id
INSERT IGNORE INTO `t2` SELECT DISTINCT t5.s_id FROM `smw_di_wikipage` AS t5 WHERE t5.p_id='148394' AND t5.o_id='7236' - Temporary table t4
Recursively computed hierarchy for element(s) ('14629').
SELECT s_id FROM `smw_fpt_subc` WHERE o_id='14629' LIMIT 1
Query Metrics
Query-Size:7Query-Depth:1
Errors and Warnings
None