Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Urgent. How to make a ODBC SQLExecDirect with PB 8.0.1

30 views
Skip to first unread message

PicheBert

unread,
Jul 11, 2003, 11:11:49 AM7/11/03
to
Hi,

What is the easiest way to call a stored procedure on a DBMS with a
SQLExecDirect function through ODBC.

The old way to call a stored procedure with PB6.5.1 is SQLExecDirect but
now with PB8.0.1 use a SQLPrepare and different call to update the
parameters. The DBMS I use does not support this.

Thanks,

Sanjiv Das [TeamSybase]

unread,
Jul 11, 2003, 10:58:13 PM7/11/03
to
Are SQLPrepare and SQLExecDirect methods that you have written or in a
foundation class ?

I am not sure exactly what you are trying to achieve, but why can't you just
execute the stored procedure using dynamic SQL ?

Perhaps you could post a few additional details, such as what DBMS you are
using and the code you use to execute the stored proc.

Sanjiv.


<PicheBert> wrote in message
news:09A95E4D79A853D400537AAF85256D60.00537AFB85256D60@webforums...

PicheBert

unread,
Jul 14, 2003, 10:09:57 AM7/14/03
to
Hi,

I am connected to a NonStop SQL on a Tandem hardware.

The problem is related to way who PB 8 make a call to the DBMS. The old
version of PB 6.5.1 with a SQL Embeded create a Execdirect for the stored
procedure. And that work fine.

PB 8.0.1 make the same call totaly different. PB 8.0.1 call a SQL Prepare
and for each parameter, PB8 make a SQLBindParameter. At the first
SQLBindPrarmeter ODBC make an error 'Incompatible type'.

If you have any suggestion.

Jim O'Neil [Sybase]

unread,
Jul 14, 2003, 2:55:44 PM7/14/03
to
Try setting DisableBind=1 in your DBParm.

Jim O'Neil
Principal Technical Support Engineer
Sybase, Inc.
Concord, MA

Pichebert

unread,
Jul 14, 2003, 4:26:05 PM7/14/03
to
I have already test this option.

Does not work, the error still there.

Thanks,

Pichebert

unread,
Jul 14, 2003, 4:26:30 PM7/14/03
to

Jim O'Neil [Sybase]

unread,
Jul 14, 2003, 6:08:23 PM7/14/03
to
Are you certain you set the parameter correctly? The whole purpose of
DisableBind=1 is to NOT bind to parameter markers; therefore, you
should never see the SQLBindParameter call being made by PowerBuilder.

Make certain that you do not include DisableBind inside of the
ConnectString - they are two distinct DBParms.

Jim O'Neil

Sanjiv Das [TeamSybase]

unread,
Jul 22, 2003, 12:55:24 AM7/22/03
to
Could you post the code where you set the SQLCA attributes and connect to
the database ? Have you also tried tracing the database activity from the PB
app ? You can do this by prefixing the DBMS attribute with 'TRACE '

Sanjiv.


<Pichebert> wrote in message
news:1F79EB7B835A7A7500704A5485256D63.007003BD85256D63@webforums...

0 new messages