Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Obtaining a higher precision in timestamp
Message
 
 
To
21/03/2014 11:38:33
General information
Forum:
Microsoft SQL Server
Category:
Other
Environment versions
SQL Server:
SQL Server 2008
Application:
Web
Miscellaneous
Thread ID:
01597037
Message ID:
01597047
Views:
37
This message has been marked as a message which has helped to the initial question of the thread.
>>As Naomi just said, there's DateTime2....also, you want to populate it using the function SYSDATETIME()
>
>What would be the equivalent of SYSDATETIME() in VB.NET? For now, I use Date.Now.

DateTime.Now doesn't seem to be precise enough :(

http://msdn.microsoft.com/en-us/library/system.datetime(v=vs.110).aspx

See also

http://stackoverflow.com/questions/7119021/sql-server-2008-stored-procedure-with-datetime2


Looks like we need to search for more precise .NET DateTime class.

>
>>I believe DateTime2 goes down to the nanoseconds.
>
>Yes, that is correct.
>
>>Here's a very good article that covers it:
>>http://blog.sqlauthority.com/2010/06/11/sql-server-difference-between-datetime-and-datetime2/
>
>Thanks
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform