-2

Is there a way to know where an inserted row in a table came from? For example knowing if someone inserted it through back-end or some stored procedure created it or even when it was created?

Bohn
  • 26,091
  • 61
  • 167
  • 254
  • Possible duplicate of [Log record changes in SQL server in an audit table](http://stackoverflow.com/questions/19737723/log-record-changes-in-sql-server-in-an-audit-table) – Igor Mar 17 '17 at 15:59

1 Answers1

2

Not unless you add some sort of audit trail to your records, like a CreatedByID or a SourceSystemID or something like that. Same goes for when it was added (need a CreatedOn datetime column that is reliably filled in).

Andy_Vulhop
  • 4,699
  • 3
  • 25
  • 34