Re: Help! join with dates
"SELECT * FROM data1108 WHERE amount = 5 AND type = 3 AND CLng(cdate(date)) BETWEEN CLng(CDate(date1)) AND CLng(CDate(date2)) UNION SELECT * FROM data1208 WHERE amount = 5 AND type = 3 AND CLng(cdate(date)) BETWEEN CLng(CDate(date1)) AND CLng(CDate(date2))"
This should return all the values from both tables. Might I ask though, why you have more than one table with the same columns? And why the numbers in the table name after "data" look like dates? :)
Also moved to Database Development forum.
Re: Help! join with dates
This would be a database question, but anyway, what your after is a union query.
Heres a link: http://www.w3schools.com/sql/sql_union.asp
Re: Help! join with dates
Why are you converting a date to a Long?