Round .net DateTime milliseconds, so it can fit the sqlserver milliseconds

Posted by stacker on Stack Overflow See other posts from Stack Overflow or by stacker
Published on 2010-05-20T09:25:55Z Indexed on 2010/05/20 9:30 UTC
Read the original article Hit count: 324

Filed under:
|
|

I want to convert the datetime value to the value that I will get from sql server 2008.

Sql server truncate the milliseconds to 3 digits, so I truncate the milliseconds already. But the problem is that as you can see here: http://stackoverflow.com/questions/634122/milliseconds-wrong-when-converting-from-xml-to-sql-server-datetime sql server also has an precision issue.

© Stack Overflow or respective owner

Related posts about c#

Related posts about datetime