Drop if exists for stored procedures

wjviiwjvii Posts: 3
edited July 8, 2006 3:45AM in SQL Compare Previous Versions
Is there an option to script a drop if exists for all stored procedure differences found? Ocassionally we have "manually" updated a particular production database with a new stored procedure and then when we run the standard update scripts created by SQL Compare against the other production databases it fails just in that one database because the actual one we used for comparison to generated the scripts doesn't have it and yet otherwise the were all identical.

Hope that made sense.

Comments

  • Brian DonahueBrian Donahue Posts: 6,590 New member
    Hello,

    I believe I know what you're talking about: mainly that rather than SQL Compare's behaviour of ALTER PROCEDURE, you would like it to do what Enterprise Manager does (if exist drop... CREATE PROCEDURE).

    We have had this suggested to us before, but for technical reasons, (mostly to do with script performance) we haven't implemented it.
  • Yes that is exactly what I am talking about. Even if the script will execute more slowly it solves a lot of problems. This may be why Enterprise Manager does it by default. At the very least the option to include it would be a great feature.
This discussion has been closed.