Problem with an SQL + MS Access DB. 500 Points.
Posted on 2004-11-22
I have an Access database to wich i connect through Dim DBConnection As String = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\mydb.mdb".
I have this SQL query: SELECT a.* FROM Fisa a,Exp f WHERE a.nou_ID=f.nou_id AND (StartDate BETWEEN f.data1 and f.data2) AND (EndDate BETWEEN f.data1 AND f.data2)
where StartDate=6/15/2002 and EndDate=9/24/2002
f.data1 is 1/20/2000 and f.data2=1/20/2005
I tryed these two variables as (date and as string ) dim StartDate,AndDate As Date.
The result i get is null, there is no record between those two dates. (In my databse there are about 10 records between those dates).
What do I do wrong???
Thanks a lot.