Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

How to tell when a row was last updated

Posted on 2009-05-15
6
Medium Priority
?
406 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 1

Accepted Solution

by:
whittet earned 2000 total points
ID: 24399714
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
ID: 24401168
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
ID: 24401210
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
The Eight Noble Truths of Backup and Recovery

How can IT departments tackle the challenges of a Big Data world? This white paper provides a roadmap to success and helps companies ensure that all their data is safe and secure, no matter if it resides on-premise with physical or virtual machines or in the cloud.

 
LVL 31

Expert Comment

by:RiteshShah
ID: 24401241
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
ID: 24402989
>>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
ID: 31582106
Thanks!
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Ever wondered why sometimes your SQL Server is slow or unresponsive with connections spiking up but by the time you go in, all is well? The following article will show you how to install and configure a SQL job that will send you email alerts includ…
In this article we will learn how to fix  “Cannot install SQL Server 2014 Service Pack 2: Unable to install windows installer msi file” error ?
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.
Via a live example, show how to setup several different housekeeping processes for a SQL Server.

704 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