Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Other Forums
 MS Access
 Filter's

Author  Topic 

Core
Starting Member

15 Posts

Posted - 2008-04-28 : 13:59:25
Hello,

How can i filter something then turn it to filter again and one more time , like :

SELECT * FROM Tbl1 WHERE BLABLA1

From those results

WHERE BLABLA 2

And Finally , from all back results

WHERE BLABLA 3.

Real Example: Select all where : the year is between x and y, then the month is beetwen z and w, and finally, where the days is beetween v and t.

Dont Work:
SELECT * FROM table WHERE (FORMAT(datainicio, "dd") >= '01' AND FORMAT(datainicio, "dd") <= '19')

AND (FORMAT(datainicio, "mm") >= '01' AND FORMAT(datainicio, "mm") <= '04')

AND (FORMAT(datainicio, "yyyy") >= '2005' AND FORMAT(datainicio, "yyyy") <= '2009') ORDER BY

Ps. Can't use the Beetween because it's a char fieldRegards, many regards.
Core
   

- Advertisement -