Click to See Complete Forum and Search --> : Programmatically Extract Stored Procedures


Joe Gerstl
03-22-2000, 09:56 AM
Can anyone tell me how to programmatically extract stored procedures (like
SQL Enterprise Manager's Generate SQL Scripts function)?

learndbms learndbms
03-22-2000, 02:10 PM
"Joe Gerstl" <joeg@mountainsystems.com> wrote:
>
>Can anyone tell me how to programmatically extract stored procedures (like
>SQL Enterprise Manager's Generate SQL Scripts function)?
>

Using sp_helptext storedprocedurename you will get the sptext, may be you
can try to save the result in an HTML using sp_makewebtask stored procedure.
may be this will give you a start.

Neil Pike
03-22-2000, 03:53 PM
Joe - use the DMO api

> Can anyone tell me how to programmatically extract stored procedures (like
> SQL Enterprise Manager's Generate SQL Scripts function)?
>

Neil Pike MVP/MCSE. Protech Computing Ltd
(Please reply only to newsgroups)
SQL FAQ (428 entries) see
forumsb.compuserve.com/vlforums/UK/default.asp?SRV=MSDevApps (sqlfaq.zip - L7
- SQL Public)
or www.ntfaq.com/sql.html
or www.sql-server.co.uk
or www.mssqlserver.com/faq

Joe Gerstl
03-23-2000, 02:06 AM
Both great suggestions. Thanks!

Neil Pike <neilpike@compuserve.com> wrote:
>Joe - use the DMO api
>
>> Can anyone tell me how to programmatically extract stored procedures (like
>> SQL Enterprise Manager's Generate SQL Scripts function)?
>>
>
> Neil Pike MVP/MCSE. Protech Computing Ltd
> (Please reply only to newsgroups)
> SQL FAQ (428 entries) see
> forumsb.compuserve.com/vlforums/UK/default.asp?SRV=MSDevApps (sqlfaq.zip
- L7
>- SQL Public)
> or www.ntfaq.com/sql.html
> or www.sql-server.co.uk
> or www.mssqlserver.com/faq
>
>