I'm trying to add "All" option to a combobox and encountering difficulties with 'Where' clause of a UNION query.
Please suggest how to correct the following SQL:
The where clause is not working, however, this query worked before I converted it to a UNION query. Thanks, Mila
Please suggest how to correct the following SQL:
Code:
SELECT Distinct tbl_Samples.sample_name, tbl_Samples.run_name FROM
tbl_Samples UNION Select 0 as AllChoice, "(All)" as Bogus from tbl_Samples
WHERE (((tbl_Samples.sample_name) Not Like "*QC*") AND
((tbl_Samples.run_name)=[Forms]![frm_First_Review_Comments]![frmReview_One].[Form]![txtCurrentRun].[Caption]));
The where clause is not working, however, this query worked before I converted it to a UNION query. Thanks, Mila