Link to home
Start Free TrialLog in
Avatar of APD Toronto
APD TorontoFlag for Canada

asked on

How to Read and Use Timestamp in MSSQL

Hi Experts,

I have MSSQL 2008 R2 database table, which has a timestamp field, but I am wondering how can I read and use this in a WHERE clause?

A sample timestap is
0x0000000000035647

Thank you
Avatar of Scott Pletcher
Scott Pletcher
Flag of United States of America image

You can't use it in any meaningful way.  It really doesn't have anything to do with time.  It's just a sequential counter.
Avatar of APD Toronto

ASKER

I thought it was a date/time of when a record is changed?

If it is a sequential counter, does it update when a record is updated?
SQL Server uses it internally as a unique counter.  That name is confusing -- the new name/data type is "rowversion", which is more accurate.
So I cannot use to find out which records were recently updated?
ASKER CERTIFIED SOLUTION
Avatar of Scott Pletcher
Scott Pletcher
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial