Click here to Skip to main content
15,893,668 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hello i am wondering how ti retrieve data from sql table arcording to the date..

as an example. if i would like to retrieve a specific or a row of data from a table from date a.

SQL
select * from table where table.date = a;


but i would like to make a command to retrieve a data to retrieve data when it was equal to date a or before the date a..

SQL
select * from table where table.date = a or ......;


can anyone help me to continue this?? or may be i got some error on the format ..
Posted

1 solution

"Date before" is equivalent to "date less than or equal" so :
SQL
select * from [table] where [table].[date] <= a
 
Share this answer
 
Comments
arnoldxx 17-Apr-14 2:28am    
thanks my friend.. you help me a lot.. :D

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900