Friday, March 23, 2012

export all StoredProcedures in a TextFile

hello,
is it possible to export the content of all stored procedures from a
database in a textfile
thanks
XavierYou can use 'script database' in the enterprise manager and then select
stored procedures.
MC
"Xavier" <Xavier@.discussions.microsoft.com> wrote in message
news:4147B6F5-1D4B-49EE-A30E-D2CAD8F1D1DD@.microsoft.com...
> hello,
> is it possible to export the content of all stored procedures from a
> database in a textfile
> thanks
> Xavier|||Lots of ways. You can use Import/Export Wizard, which in turn uses the DTS
Transfer Objects Task. You can use the Generate SQL Scripts feature in the
context menu of the database. You could query the appropriate tables in
each database:
select text from syscomments c join sysobjects o on c.id=o.id where o.type =
'P'
Mark
"Xavier" <Xavier@.discussions.microsoft.com> wrote in message
news:4147B6F5-1D4B-49EE-A30E-D2CAD8F1D1DD@.microsoft.com...
> hello,
> is it possible to export the content of all stored procedures from a
> database in a textfile
> thanks
> Xavier|||Hello Mark,
the last way you mentioned is what i need, because i must run that export
from inside ASP.NET.
What are the less rights what that the user in the database must have
example (myDbUser4Export)
in the database to execute that statement (from ASP.NET)...
thanks a lot
Xavier

No comments:

Post a Comment