lx-club
09-06-2005, 18:13
hallo...
die folgende abfrage braucht 2 sekunden. kann man das nich noch etwas beschleunigen oder is das normal so? anstatt den * habe ich auch spaltennamen angegeben, aber das bringt nix.
SELECT t1. * , t2. * , t3. *
FROM kk_produktgruppen t1
LEFT JOIN kk_produktgruppen t2 ON t1.pg_id = t2.parent_id
LEFT JOIN kk_produktgruppen t3 ON t2.pg_id = t3.parent_id
WHERE t2.parent_id IS NOT NULL
AND t3.bezeichnung IS NOT NULL
AND t3.pg_id IN ( 96, 97, 98, 99, 100, 101, 102 )
ORDER BY t1.bezeichnung ASC , t2.bezeichnung ASC , t3.bezeichnung ASC
die folgende abfrage braucht 2 sekunden. kann man das nich noch etwas beschleunigen oder is das normal so? anstatt den * habe ich auch spaltennamen angegeben, aber das bringt nix.
SELECT t1. * , t2. * , t3. *
FROM kk_produktgruppen t1
LEFT JOIN kk_produktgruppen t2 ON t1.pg_id = t2.parent_id
LEFT JOIN kk_produktgruppen t3 ON t2.pg_id = t3.parent_id
WHERE t2.parent_id IS NOT NULL
AND t3.bezeichnung IS NOT NULL
AND t3.pg_id IN ( 96, 97, 98, 99, 100, 101, 102 )
ORDER BY t1.bezeichnung ASC , t2.bezeichnung ASC , t3.bezeichnung ASC

