question

Bart_V avatar image
Bart_V asked

Cross-database dependencies get scripted

I have a problem while scripting a database with the smo.scripter class. One table contains a Stored procedure wich uses 'msdb.dbo.sp_send_dbmail'. I use the scripting options 'Withdepencies = true' and 'allowsystemobjects = false'. The result of this is that the syntax to create the sp 'msdb.dbo.sp_send_dbmail' is included in my database script. This is not wath I want. There seems to be no option to exclude "Cross-database dependencies". Any idea how I could avoid this behavior?
script-taskcross-databasesmooptions
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

0 Answers

·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.