Are you talking about a database column of TIMESTAMP
type??
Those are binary timestamp that SQL Server will update internally - they have nothing to do with date and/or time - it's just a binary-encoded counter, really. These fields are handled by the system, and they're reliable and very accurate - if you want to have some kind of an optimistic concurrency locking mechanism, use this field type.
If you want a DATETIME
field containing a date and time of the last modification, you're best option would be to have a AFTER INSERT/AFTER UPDATE trigger on that table which sets the last updated column to the current date/time of the SQL Server automatically, without you having to do anything about it.
DATETIME
in SQL Server 2005 is accurate to about 3.33ms - in SQL Server 2008, DATETIME2
can be made accurate to 100ns, if needed. As such, do not rely on a DATETIME
column for 100% accurate checking whether something has changed or not! The 3.33ms accuracy might give misleading results!