February 11th, 2013, 01:55 PM
No records returned from access db
I have a strange problem doing a simple search in my access database using Jet connection string. It is classic ASP.
if condition ="lager" then
SQL = "SELECT * FROM mydatabase where outdate = '' order by productno;"
elseif condition = "ejlager" then
SQL = "SELECT * FROM mydatabase where outdate <> '' order by productno;"
SQL="SELECT * FROM mydatabase order by productno;"
outdate is just a plain textfield.
In the first two conditions I got no records returned. When I select something else that takes me to last if then it returns all records.
It works fine when testing on my SQL db, but not in access db. Can it have something to do with UTF-8 that I have coded the page to ?
Does anyone have a solution to this then I would be very greatful and maybe litte wiser :-) .
February 11th, 2013, 02:08 PM
Should I use IS NULL and IS NOT NULL instead ?
February 11th, 2013, 02:22 PM
how you define outdate field? Date/Time? if yes you should check for null
if you found this post is useful click Give Rep button (bottom side on this reply ) and agree
February 11th, 2013, 02:43 PM
It is just a plain textfield. I can not try this before tomorrow, but I suppose it would work testing with NULL instead.