May 28, 2008 at 6:06 am
I used datetime datatype in my table.I insert only date but it store the time also.how to avoid storing time.
And also wen i retrive only data will be displayed into my datagrid
Pls help me
May 28, 2008 at 8:27 am
Hello geethag6,
It's impossible to avoid what you are asking in SQL Server 2000 or SQL Server 2005
It would be possible in SQL Server 2008 you can test if you install SQL Server 2008 CTP(Not Final yet)!
But after you create the table and inserting date you will retrieve the data using views or just SELECT statement like this:
SELECT col1, datecol, CONVERT(VARCHAR, datecol, 103) as Date FROM table_name
the results will look like this:
col1 datecol Date
anytext date(with date and time) dd/mm/yyyy
Hope this help to you!
Dugi
May 28, 2008 at 11:09 pm
Hi,
Thank u very much i got the result.
Regards
Geetha
May 29, 2008 at 12:51 am
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply