I want to check if a list of stored procedures exist. I want this all to be done in 1 script, one by one. So far I have this format:
USE [myDatabase] GO IF NO
USE [myDatabase] GO IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'sp_1') BEGIN DROP PROCEDURE sp_1 END GO --<-- Add a Batch Separator here CREATE PROCEDURE sp_1 AS ................. END GO