I am using the following statement to search through a database.
Set RS = DB.OpenRecordset("SELECT * FROM Table1 WHERE '" & SearchField & "' = '" & KeyWord & "'", dbOpenDynaset)

Where "SearchField" and "Keyword" are the variables entered by the program user. But the problem is that the above statement does not result in any records relating to user specified keyword but always displays the first record in the database.
No errors are shown at runtime.

Please help.


Kinjal

[Edited by kinjalgp on 06-27-2000 at 01:32 PM]