Skip to Content.
Sympa Menu

freetds - [freetds] status: db-lib rpc works

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Lowden, James K" <LowdenJK AT bernstein.com>
  • To: "FreeTDS Development Group" <freetds AT lists.ibiblio.org>
  • Subject: [freetds] status: db-lib rpc works
  • Date: Thu, 25 Mar 2004 14:35:41 -0500

> From: James K. Lowden [mailto:jklowden AT schemamania.org]
> Sent: March 25, 2004 12:05 AM
> On Thu, 25 Mar 2004, "Polyanovskyi, Sasha"
> <sasha.polyanovskyi AT oa.com.au>
> wrote:
> > I've changed the code to the suggested way, now neither case :-)
> > (actualy my procedures are a bit different in a number of
> params that
> > get passed)
> >
> > Suggested way:
> > while (dbresults() != NO_MORE_ROWS)
> > {
> > process columns...;
> > process return status...;
> > process results;
> > }
>
> I updated src/dblib/unittests/rpc.c to issue a more complex stored
> procedure and to (try to) process its results. The test now fails,
> meaning it correctly reports our broken rpc implementation.

The db-lib rpc functions now work. Fixes include:

1. Calling dbnumrets() immediately after dbnextrow(dbproc)) returns
NO_MORE_ROWS now works. Previously, calling any of dbnumrets() or the dbret*
family had to wait until after dbresults() returned NO_MORE_RESULTS, which
was not in accordance with the documentation.

2. dbrpcparam() has some error checking to require correct maxlen and
datalen parameters. Previously, it accepted pretty much anything, which
caused grief later on (including causing the parameter to be ignored at
dbrpcsend() time).

3. The rpc unit test is a diamond-cut model of exemplary parameter passing.
;-)

The above changes apply to current CVS, and will appear in tomorrow's
snapshot.

--jkl

-----------------------------------------
The information contained in this transmission may contain privileged and
confidential information and is intended only for the use of the person(s)
named above. If you are not the intended recipient, or an employee or agent
responsible for delivering this message to the intended recipient, any
review, dissemination, distribution or duplication of this communication is
strictly prohibited. If you are not the intended recipient, please contact
the sender immediately by reply e-mail and destroy all copies of the original
message. Please note that we do not accept account orders and/or instructions
by e-mail, and therefore will not be responsible for carrying out such orders
and/or instructions.
If you, as the intended recipient of this message, the purpose of which is to
inform and update our clients, prospects and consultants of developments
relating to our services and products, would not like to receive further
e-mail correspondence from the sender, please "reply" to the sender
indicating your wishes. In the U.S.: 1345 Avenue of the Americas, New York,
NY 10105.





  • [freetds] status: db-lib rpc works, Lowden, James K, 03/25/2004

Archive powered by MHonArc 2.6.24.

Top of Page