relative insert timestamps | SQL Server Performance Forums

SQL Server Performance Forum – Threads Archive

relative insert timestamps

Is there any way to determine the time a record was inserted either absolutely or relevant to other records.
Assume I have a table defined as x int, y timestamp
I have 3 rows 1,2005-06-20 09:41:12
2,2005-06-21 09:41:12
3,2005-06-22 09:41:12 I need to find out the order the records were inserted. The timestamp is used in a form of ETL, but I’m pretty sure in my case row 2 was inserted after the ETL was run so it’s missing from the target DB. I need to find a way of proving it. Chatty
The sample data is not enough to give solution
In this case Date part differs
Madhivanan Failing to plan is Planning to fail
Hi,
keep your first column as identity int column and let the system assign auto value so that you can guarantee that which record was inserted first.
as your data shows time can be same so go for first column value.
I’m afraid this is data that is already there and the tables cannot be modified.
I was hoping for something like a page timestamp for archive purpose or something else like that that I could actually track physical disk i/o modification with. Logs are out as the data was inseted over a month ago. I should have been a little less verbose with the sample data, assume thay there is only one column and 2 rows a
b Which was inserted first(assuming they are on different pages)?
TBH I don’t really expect to be able to resolve this. Chatty

I’m afraid this is data that is already there and the tables cannot be modified.
I was hoping for something like a page timestamp for archive purpose or something else like that that I could actually track physical disk i/o modification with. Logs are out as the data was inseted over a month ago. I should have been a little less verbose with the sample data, assume thay there is only one column and 2 rows a
b Which was inserted first(assuming they are on different pages)?
TBH I don’t really expect to be able to resolve this. Chatty

I’m absolutely not sure what you’re after.
Can you given some more information why this is so important to you?
Just asking, because I think you’re most likely out of luck. But who knows anyway? —
Frank Kalis
Microsoft SQL Server MVP
http://www.insidesql.de
Ich unterstütze PASS Deutschland e.V. http://www.sqlpass.de)

There is no way where you could determine which row was inserter first without a timestamp and identity on a column. You will not be able to extract this information from pages or from the actual file. Sorry Raj
]]>