Script Referential Integrity from a database;

  • Hi all , Is there a way to script just the referential integrity and constraints using powershell? I want to automate that scripting process. I have scripts to scripts,tables, indexes separately but not RI's. Any information is appreciated.

    Thanks

  • You can script PKs and FKs the same way you script tables or indexes; that would do it.

    _____________________________________
    Pablo (Paul) Berzukov

    Author of Understanding Database Administration available at Amazon and other bookstores.

    Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.

Viewing 2 posts - 1 through 1 (of 1 total)

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