History of dropped constraints

  • Hi,

    I found few of the foreign key constraints got dropped in some of our SQL Instances. Is there any way to find out when it got dropped? Will SQL have history on such dropped constraints / objects.

    Please help....

    Thanks in Advance

  • You can check the default trace. It should store that event, but it doesn't keep the data forever (5 files of 20MB each). If it's not in the default trace and you didn't have a manual trace running, then there's no way to see who dropped it and when.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • Thanks for your quick response. Can you help how to get/use that default trace to identify?

  • Thanks for your Quick response. Can you please help how to get/use that default trace?

  • http://msdn.microsoft.com/en-us/library/ms175513.aspx

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • You may be able to see it in the Schema Changes History standard report.It only shows changes since the last time the service started.

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply