I have a very simple select query which a user types in a record number, the query searches the database and if the record number exists, it pulls up a form that has data pertaining to this record number. However my problem is if there is no record number in the database, I would like a different form to open allowing them to enter the information on this record number. Does anyone have any suggestions.
Thanks
Below is my SQL if this helps
SELECT [Work Assignments].CID, [Work Assignments].[assignment#], [Work Assignments].[Quote/Policy], [Work Assignments].NameInsured, [Work Assignments].City, [Work Assignments].StateNo, [Work Assignments].RLB, [Work Assignments].specialinstructions, [Work Assignments].surveycomplete
FROM [Work Assignments]
GROUP BY [Work Assignments].CID, [Work Assignments].[assignment#], [Work Assignments].[Quote/Policy], [Work Assignments].NameInsured, [Work Assignments].City, [Work Assignments].StateNo, [Work Assignments].RLB, [Work Assignments].specialinstructions, [Work Assignments].surveycomplete
HAVING ((([Work Assignments].CID)=[Forms]![frmcidnumberscreen]![CIDnumber]) AND (([Work Assignments].surveycomplete)=False));
Thanks
Below is my SQL if this helps
SELECT [Work Assignments].CID, [Work Assignments].[assignment#], [Work Assignments].[Quote/Policy], [Work Assignments].NameInsured, [Work Assignments].City, [Work Assignments].StateNo, [Work Assignments].RLB, [Work Assignments].specialinstructions, [Work Assignments].surveycomplete
FROM [Work Assignments]
GROUP BY [Work Assignments].CID, [Work Assignments].[assignment#], [Work Assignments].[Quote/Policy], [Work Assignments].NameInsured, [Work Assignments].City, [Work Assignments].StateNo, [Work Assignments].RLB, [Work Assignments].specialinstructions, [Work Assignments].surveycomplete
HAVING ((([Work Assignments].CID)=[Forms]![frmcidnumberscreen]![CIDnumber]) AND (([Work Assignments].surveycomplete)=False));