Language: SQL
Script to create commands to remove all foreign keys in a database
SELECT 'ALTER TABLE ' + TABLE_SCHEMA + '.[' + TABLE_NAME + '] DROP CONSTRAINT [' + CONSTRAINT_NAME + ']' FROM information_schema.table_constraints WHERE CONSTRAINT_TYPE = 'FOREIGN KEY'
Tags:
Report Abuse
Subscribe
Discuss
What's new
What is it
New Snippet
Recent Snippets
My Snippets
Web Code
Search

