C
Charles A. Lackman
Hello,
I have created an application that queries an Jet4 Database (Access) and am
using the following command to return a particular results:
ASelect = "SELECT * FROM Employee WHERE [Description] LIKE '%" &
txtDescription.text & "%' ORDER BY [Last Name]"
This works great but when the Description textbox has a ' in it an error is
returned. Is there a way to allow ' inside the sql string?
I have tried:
ASelect = "SELECT * FROM Employee WHERE [Description] LIKE [%" &
txtDescription.text & "%] ORDER BY [Last Name]"
and it does not work. Any Suggestions would be greatly appreciated.
Thanks,
Chuck
I have created an application that queries an Jet4 Database (Access) and am
using the following command to return a particular results:
ASelect = "SELECT * FROM Employee WHERE [Description] LIKE '%" &
txtDescription.text & "%' ORDER BY [Last Name]"
This works great but when the Description textbox has a ' in it an error is
returned. Is there a way to allow ' inside the sql string?
I have tried:
ASelect = "SELECT * FROM Employee WHERE [Description] LIKE [%" &
txtDescription.text & "%] ORDER BY [Last Name]"
and it does not work. Any Suggestions would be greatly appreciated.
Thanks,
Chuck