Board index » delphi » Passing Date as parameter to dataTime field in SQL database

Passing Date as parameter to dataTime field in SQL database

Hi

Is there way to select data from using date as the parameter to the datatime
field in the table?

e.g date parameter 01/01/2001

Table Data:
01/01/2001 1:00AM
01/01/2001 2:00AM
02/01/2001 1:00AM

I want to be able to pick the first 2 records.

Cheers
James

 

Re:Passing Date as parameter to dataTime field in SQL database


try using between clause using datetime like this:

01/01/2001 0:0:0 and 02/01/2001 0:0:0

Regards

Eduardo

James <jam...@hlaustralia.com.au> escribi en el mensaje de noticias
3b0ca7cb_1@dnews...

Quote
> Hi

> Is there way to select data from using date as the parameter to the
datatime
> field in the table?

> e.g date parameter 01/01/2001

> Table Data:
> 01/01/2001 1:00AM
> 01/01/2001 2:00AM
> 02/01/2001 1:00AM

> I want to be able to pick the first 2 records.

> Cheers
> James

Other Threads