Solved

How to tell when a row was last updated

Posted on 2009-05-15
6
362 Views
Last Modified: 2012-05-07
What is the best way to find out when a row was last updated when I have read-only access to a DB?

0
Comment
Question by:stephi01
6 Comments
 
LVL 1

Accepted Solution

by:
whittet earned 500 total points
Comment Utility
At minimum the table in question must have a datetime column with default set to now() or date().  

If your table doesn't have this yet, I think you're out of luck.
0
 
LVL 31

Expert Comment

by:RiteshShah
Comment Utility
whittet,

his database is readonly so no matter when his row is going to update, field will not get update anyhow. I don't think so this is possible in this perticular case.
0
 
LVL 1

Expert Comment

by:whittet
Comment Utility
The question clearly stated that only reading data was to occur.  My prior comment is intended to allow inspection of SQL 2005 configuration (i.e. DDL) to determine whether a particular datetime field was populated with the relevant time stamp.
0
What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 
LVL 31

Expert Comment

by:RiteshShah
Comment Utility
whittet,

you are right indeed, I wasn't arguing that you were wrong, I just wanted to update Author that it is somehow not possible with any DMVs or anything else, if he has updated timestamp or other datetime field, he is not able to do so.
0
 
LVL 75

Expert Comment

by:Anthony Perkins
Comment Utility
>>his database is readonly so no matter when his row is going to update<<
Actually, no.  The author stated they "have read-only access to a DB" which is not the same as the "database is readonly".

But unless they have some way of identifying when a row is changed it really does not matter.
0
 

Author Closing Comment

by:stephi01
Comment Utility
Thanks!
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Suggested Solutions

Introduction In my previous article (http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/SSIS/A_9150-Loading-XML-Using-SSIS.html) I showed you how the XML Source component can be used to load XML files into a SQL Server database, us…
Slowly Changing Dimension Transformation component in data task flow is very useful for us to manage and control how data changes in SSIS.
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now