|
ms
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Get a list of available stored proceduresHi there:
I would like to retrive a collection with the avvaialbe stored procedures, if there are any, I m using an ODBC connection, How can this be achieved? I know u can do a select of one of the system tables with a sql server, but what happens if i dont have a sql server? Cheers Hi,
What DB r u using? In SQL server it's kept in a system table (sysobjects IIRC). Why are u using a ODBC connection though? Show quote "roundcrisis" <roundcri***@gmail.com> wrote in message news:e00dca7c-57c9-4e3d-9fe9-8dc01e5ca061@d4g2000prg.googlegroups.com... > Hi there: > > I would like to retrive a collection with the avvaialbe stored > procedures, if there are any, > I m using an ODBC connection, > How can this be achieved? > I know u can do a select of one of the system tables with a sql > server, but what happens if i dont have a sql server? > Cheers On Nov 28, 8:11 am, roundcrisis <roundcri***@gmail.com> wrote:
> Hi there: As far as I am aware, there is no standard ODBC method of obtaining a> > I would like to retrive a collection with the avvaialbe stored > procedures, if there are any, > I m using an ODBC connection, > How can this be achieved? > I know u can do a select of one of the system tables with a sql > server, but what happens if i dont have a sql server? > Cheers list of stored procedures on the server you are connected to. Some SQL providers do not even support stored procedures, from what I understand. So it depends on the actual provider itself on how to obtain the list of SPs. For MS SQL Server it is: select * from information_schema.routines Well, if you don't have a SQL Server, then you will have to use whatever
DB-specific method will give you a list of the stored procedures (there is not one standardized way of getting stored procedures across all data sources). Also, the provider really doesn't matter in this case (ODBC is a provider that can connect to many data sources, as is OLEDB) unless it is for one product and one product only (SQL Server, for example) and even then, it might not give you the information you want. For SQL Server, you can simply run the sp_stored_procedures stored procedure and it will return a list of stored procedures to you: http://msdn2.microsoft.com/en-us/library/ms190504.aspx -- Show quote- Nicholas Paldino [.NET/C# MVP] - mvp@spam.guard.caspershouse.com "roundcrisis" <roundcri***@gmail.com> wrote in message news:e00dca7c-57c9-4e3d-9fe9-8dc01e5ca061@d4g2000prg.googlegroups.com... > Hi there: > > I would like to retrive a collection with the avvaialbe stored > procedures, if there are any, > I m using an ODBC connection, > How can this be achieved? > I know u can do a select of one of the system tables with a sql > server, but what happens if i dont have a sql server? > Cheers
Show quote
"Nicholas Paldino [.NET/C# MVP]" <mvp@spam.guard.caspershouse.com> wrote in Just require users with other DB engines to write sp_stored_procedures in message news:OXFziSdMIHA.3400@TK2MSFTNGP03.phx.gbl... > Well, if you don't have a SQL Server, then you will have to use > whatever DB-specific method will give you a list of the stored procedures > (there is not one standardized way of getting stored procedures across all > data sources). > > Also, the provider really doesn't matter in this case (ODBC is a > provider that can connect to many data sources, as is OLEDB) unless it is > for one product and one product only (SQL Server, for example) and even > then, it might not give you the information you want. > > For SQL Server, you can simply run the sp_stored_procedures stored > procedure and it will return a list of stored procedures to you: > > http://msdn2.microsoft.com/en-us/library/ms190504.aspx their database -- it's like implementing a common interface. Then be prepared for sp_stored_procedures to show up in the list on some databases, and filter it out before showing the user... |
|||||||||||||||||||||||