Subject | where Afield in (a subselect) inefficient??? |
---|---|
Author | Michael Fung |
Post date | 2003-08-02T03:52:46Z |
Dear All,
Is the following query very inefficient as the subselect clause run
as many times as records matched in ?
SELECT some_fields_in_table_a FROM table_a TA
WHERE TA.one_indexed_field = some_value
AND TA.another_indexed_field IN (SELECT pkey FROM table_b);
I hope the subselect will only run once.
TIA.
- Michael
Is the following query very inefficient as the subselect clause run
as many times as records matched in ?
SELECT some_fields_in_table_a FROM table_a TA
WHERE TA.one_indexed_field = some_value
AND TA.another_indexed_field IN (SELECT pkey FROM table_b);
I hope the subselect will only run once.
TIA.
- Michael