Go Back  Xtreme Visual Basic Talk > Legacy Visual Basic (VB 4/5/6) > VBA / Office Integration > Word, PowerPoint, Outlook, and Other Office Products > How do i get the date of the last table update ?


Reply
 
Thread Tools Display Modes
  #1  
Old 07-27-2001, 04:07 AM
JabberWocky
Guest
 
Posts: n/a
Default How do i get the date of the last table update ?


I need to find out how to get the date a record was last added to a specific table. Possible even the last record added to a table relating to the Primary Key in another table if it's possible.

You see, I am designing a back to work interview system and could really use the facility to view the last time a sickness record was added for a specific employee.

Thanks in advance,

JabberWocky

Reply With Quote
  #2  
Old 07-27-2001, 07:03 AM
Thinker Thinker is offline
Iron-Fisted Programmer

Retired Moderator
* Guru *
 
Join Date: Jul 2001
Location: Fayetteville Arkansas USA
Posts: 18,127
Default Re: How do i get the date of the last table update ?

I think you will need to add a timestamp field to the table. Everytime you add a row, you place the current time and date in this field. Then, when you need to find the last one you can Order By Desc this field and if your SQL supports it use the TOP 1 in the Select clause. If it is related to the Primary key in another table then it is just a join.

__________________
Posting Guidelines
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Advertisement:





Free Publications
The ASP.NET 2.0 Anthology
101 Essential Tips, Tricks & Hacks - Free 156 Page Preview. Learn the most practical features and best approaches for ASP.NET.
subscribe
Programmers Heaven C# School Book -Free 338 Page eBook
The Programmers Heaven C# School book covers the .NET framework and the C# language.
subscribe
Build Your Own ASP.NET 3.5 Web Site Using C# & VB, 3rd Edition - Free 219 Page Preview!
This comprehensive step-by-step guide will help get your database-driven ASP.NET web site up and running in no time..
subscribe
 
 
-->