I am trying to fill the dataset with items only from the last 30 days.
I've tried a few different ways, but all the database rows are returned.
What is the WHERE clause I sholud use to do this??
ThanksTry with the following SQL statement, i belive it should work.
select * from <tablename> where datediff(day, <columnname>, getdate()) < 30
Hope it solves your issue.|||Thanks very much, it worked a treat
No comments:
Post a Comment