如何检索日期和时间以及记录的先前数据是否已更新? [英] How Can I Retrieval Date And Time And Previous Data Of Record Was Updated?

查看:92
本文介绍了如何检索日期和时间以及记录的先前数据是否已更新?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的朋友,

我有一个手动更新的记录。例如,它的数据是'Jon',并且由工作人员手动将其更改为'Michel'。

现在我想要检索记录的先前数据(Jon)并更新日期和工作人员发生的时间。比如显示'2014/02/03'和'9:30:20'

谢谢和遗憾。

Hi my friends,
I have a record that was updated manually. For example its data was 'Jon' and it was changed to 'Michel' by a staff manually.
Now i'll want to retrieval previous data ("Jon") of record was updated and also date and time of when it was happened by staff. For example show '2014/02/03' & '9:30:20'
Thanks and regret.

推荐答案

不是一件小事练习:您可以手动执行,通过为更改的记录添加时间戳,并在更改状态之前保留状态的存档详细信息,或者您可以使用 SQL Change Data Capture [ ^ ] - 但两者都不简单:你需要要非常小心如何处理数据库以保持数据完整性。
Not a trivial exercise: you can do it manually, by timestamping changed records, and keeping archive details of the state before they were changed, or you can use SQL Change Data Capture[^] - but neither is simple: you will need to be pretty careful about how you handle your DB in order to maintain data integrity.


这篇关于如何检索日期和时间以及记录的先前数据是否已更新?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆