473,396 Members | 2,020 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Time in status from audit trail

We have a table that is used as an audit trial

[REQUESTID] -PK
[MODIFIEDDATE] - DATETIME CHANGE WAS MADE
[FIELDNAME] - THE FILED THAT WAS CHANGED
[ORIGINALVALUE] - ORIGINAL VALUE IN FIELD
[NEWVALUE] - wHAT THE VALUE WAS CHANGED TO
[OBJECTID] -FK

the Requestid is the PK, the Object id is the FK
I need to add up all the time something was in a certain status.

How could I query and get in minutes the amount of time fieldname = 'status'
and newvalue = 'Onhold'
Please note the status could be in OnHold several times. Sorry to be a bother but I have no idea where to start with this one?
Jul 24 '07 #1
2 1037
ilearneditonline
130 Expert 100+
We have a table that is used as an audit trial

[REQUESTID] -PK
[MODIFIEDDATE] - DATETIME CHANGE WAS MADE
[FIELDNAME] - THE FILED THAT WAS CHANGED
[ORIGINALVALUE] - ORIGINAL VALUE IN FIELD
[NEWVALUE] - wHAT THE VALUE WAS CHANGED TO
[OBJECTID] -FK

the Requestid is the PK, the Object id is the FK
I need to add up all the time something was in a certain status.

How could I query and get in minutes the amount of time fieldname = 'status'
and newvalue = 'Onhold'
Please note the status could be in OnHold several times. Sorry to be a bother but I have no idea where to start with this one?
Is there any field that shows the time the value was originally created?
Jul 25 '07 #2
Is there any field that shows the time the value was originally created?
The way it is setup the modifieddate shows the time stamp of when ever their is a change. It would be in seperate entried one that field name = status and newvalue='onhold' and then when it is changed it would be a seperate entry wher fieldname = status and oldvalue = "onhold'
Jul 25 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

6
by: Raphael Gluck | last post by:
Hi, Is it possible for one to program one's pages as such that when a database table is updated over the web, via a form, that an e-mail confirmation is sent to a specified address, notifying...
2
by: Zlatko Matić | last post by:
I tried to implement triggers for filling audit-trail table on this way. Everything works fine as long as I don't update the primary key field value. When I try to update PK value, an error...
3
by: Zlatko Matić | last post by:
Hello. I tried to implement audit trail, by making an audit trail table with the following fileds: TableName,FieldName,OldValue,NewValue,UpdateDate,type,UserName. Triggers on each table were...
8
by: allyn44 | last post by:
Helllo--I have implemented the audit trail from the Microsoft KB article that records changes on a data entry form to a memo filed in the fieeld's table record. What I would like to do is pull...
0
by: hary08 | last post by:
I have a module copied ftom this site, here it is: Option Compare Database Option Explicit Public Function AuditTrail() On Error GoTo Err_Audit_Trail 'ACC2000: How to Create an Audit...
3
by: hary08 | last post by:
im doing a database for Hospital Admission, I have a log in form which prompt user for a password. The source of log in is to look for the values in my Table tblEmployees and match user name and...
2
by: mnarewec | last post by:
Hi Team I am instructed to keep an audit trail of when a record is updated/deleted/ or inserted. The user is using a datagridview to update tables which is bound to a dataset. . How can I...
16
by: zandiT | last post by:
hello i'm using the microsoft audit trail example ACC2000: How to Create an Audit Trail of Record Changes in a Form and im having a problem with my recordset. in the example they are using a...
4
by: Emin | last post by:
Dear Experts, We need to design a database which has an audit trail for updates to a certain set of tables. The two main approaches I've seen for this include shadow tables (an extra table to...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.