Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

Stored Procedures and ADOX

2 posts in iAnywhere General Discussion (German) Last posting was on 2008-04-01 08:00:10.0Z
egarlaschelli Posted on 2008-03-31 15:09:38.0Z
Sender: 1ce2.47f0c2aa.1804289383@sybase.com
From: egarlaschelli
Newsgroups: ianywhere.public.german.general
Subject: Stored Procedures and ADOX
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <47f0feb2.229d.1681692777@sybase.com>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 31 Mar 2008 07:09:38 -0800
X-Trace: forums-1-dub 1206976178 10.22.241.41 (31 Mar 2008 07:09:38 -0800)
X-Original-Trace: 31 Mar 2008 07:09:38 -0800, 10.22.241.41
Lines: 16
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.german.general:439
Article PK: 1108

I first have to say that I'm quite new in Database
programming.

What I'm trying to do, is to understand the queries and the
ways to add/insert... that are concealed in a lot of stored
procedures in a ASA Database I'm working with.

Is it possible to get the code of a stored procedure within
a visual basic programm using AD0/ADOX?

For instance, SQL Server provides an object library
(SQLDMO), which has a StoredProcedure object that has a Text
property
(something like: dbProcedure.Command.CommandText)

Many Thanks for Your time


"Frank Ploessel" <fpl... Posted on 2008-04-01 08:00:10.0Z
Subject: Re: Stored Procedures and ADOX
From: "Frank Ploessel" <fpl...@d_e.i_m_s_h_e_a_l_t_h.c_o_m>
Content-Type: text/plain; format=flowed; delsp=yes; charset=iso-8859-15
MIME-Version: 1.0
Newsgroups: ianywhere.public.german.general
References: <47f0feb2.229d.1681692777@sybase.com>
Content-Transfer-Encoding: Quoted-Printable
Message-ID: <op.t8w9uhzqj0bybf@bonw00164.internal.imsglobal.com>
User-Agent: Opera Mail/9.21 (Win32)
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Date: 1 Apr 2008 00:00:10 -0800
X-Trace: forums-1-dub 1207036810 10.22.241.152 (1 Apr 2008 00:00:10 -0800)
X-Original-Trace: 1 Apr 2008 00:00:10 -0800, vip152.sybase.com
Lines: 45
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub ianywhere.public.german.general:440
Article PK: 1109

Egarlaschelli,

This is the German speaking forum, so the normal language is German, not
English.

But, to answer your question (assuming you are using ASA 9 or 10), use:
select source from sys.sysprocedure where proc_name='your_procedure_name'

Depending on the PRESERVE_SOURCE_FORMAT option in the database, column
source may be empty, and you may only have data in column proc_defn (this
is the procedure definition reformatted by SQL Anywhere). Please be aware
that in ASA10, the procedure definition may be hidden, which means it is
not be readable at all.

Frank

On Mon, 31 Mar 2008 17:09:38 +0200, <egarlaschelli> wrote:

> I first have to say that I'm quite new in Database
> programming.
>
> What I'm trying to do, is to understand the queries and the
> ways to add/insert... that are concealed in a lot of stored
> procedures in a ASA Database I'm working with.
>
> Is it possible to get the code of a stored procedure within
> a visual basic programm using AD0/ADOX?
>
> For instance, SQL Server provides an object library
> (SQLDMO), which has a StoredProcedure object that has a Text
> property
> (something like: dbProcedure.Command.CommandText)
>
> Many Thanks for Your time