
June 18th, 2004, 08:31 PM
|
|
Registered User
|
|
Join Date: Jun 2004
Location: Singapore
Posts: 28
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
|
datetime convert to text
Currently i have no problem using SQL analyser to filter by date.
Select * from Table1
Where (Date# Between '15-jun-02' And '19-jun-04 23:59:59')
However i am not able to enable user to enter their own perferred date through the webpage using Request.Form.
Is it true that if i need user to specified the date on the webpage, then i need to convert the input first before using it to retrieve the record according to the date?
If so, converting the input is easier or convert the date first before comparing is easier?
Is there anyway that MS SQL Server can convert the field Date#, datatype=datetime, default value=getdate(), to another field to text automatically?
If cannot, then what is the sql statement to convert datetime to text? Or how to convert the input in order to compare with the date?
By thw way what is the meaning of using %?
|