Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
wotrac
Yak Posting Veteran
98 Posts |
Posted - 2004-11-25 : 16:00:05
|
| HiHow do I convert the following string26/11/04 to the datetime datatype.NB. This is in the following format dd/mm/yy |
|
|
scullee
Posting Yak Master
103 Posts |
Posted - 2004-11-25 : 16:59:57
|
| Have a look in books online about the convert functionbutdeclare @datevalue datetime select @datevalue = CONVERT ( datetime , '26/11/04' ,3 )If the year was four digits the format (end param) would be 103 |
 |
|
|
wotrac
Yak Posting Veteran
98 Posts |
Posted - 2004-11-25 : 17:21:39
|
| Thanks for the helpI managed to work it out for myself, just before you replied. |
 |
|
|
|
|
|