Information générale
Forum:
Microsoft SQL Server
Also, if you look at the other thread I started in SQL Syntax section on 'Self Join-challenge' this discusses using a self-join on the audit table to get the previous audit record for the specific primary key. Once you have that, you can compare old value to new value, and if they are different, then you know you have a change.
BOb
>Hi everyone...
>I've a table that is used as log of updates made in other tables by the users through the applications... Triggers were created in every single table I'd like to have update control... Today I know the moment that a table was modified and who (user) did it... But I also need to know which columns where modified and this is my problem... If I put a UPDATED() statement inside the trigger i think maybe my application will loose performance (because i will fill it with IFs)... Does anybody know how to log changes made in a table and in its columns? Has someone done this yet?
>
>Thankz...
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement