Skip to Content.
Sympa Menu

freetds - RE: [freetds] two questions about executing stored procedures

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: RE: [freetds] two questions about executing stored procedures
  • Date: Wed, 5 Jan 2005 13:45:34 -0500

> From: Kall, Bruce A.
> Sent: Wednesday, January 05, 2005 11:12 AM
>
> I have compiled the download from freetds-0.64.dev.20050103 and
> installed it on my Linux machine. In the freetds/src/dblib/unittests
> dir, I do a
>
> make check-TESTS (as there is not test.sh as is described in the
README)

Thanks for pointing that out. The command you want is "make check", cf.
http://www.freetds.org/userguide/confirminstall.htm#TESTS .

> running rpc does about the same thing:
>
> ./rpc
> found JDBC.tempdb for guest in "../../../PWD"

That message is meant as a clue to where the test machine and login
account is being read from. To run "make check", your PWD file has to
be right. To run any particular unit test, the programs accept
command-line options:

$ (cd build/src/dblib/unittests/; ./rpc -h)
rpc: unknown option -- h
usage: rpc
[-U username] [-P password]
[-S servername] [-D database]
[-i input filename] [-o output filename] [-e error filename]

These options override anything found in PWD.

> Being new to sybase stuff, it seems like JDBC is some Sybase machine

Correct, except, as you found, "was" would be more accurate.

> I can't even ping 192.138.151.39

Probably "make check" should parse PWD, ping the target server, and, if
it fails, advise you to update the file or rearrange your network.

>
> Is there something else I need to set up to get this test to run?
>
>
> Lowden, James K wrote:
> > Hi Bruce,
> >
> > OK, let's take this back on-list, shall we? The fellow who worked
on
> > the parameter passing will be interested in your experience.
> >
> > The thing to do next is to make the problem reproduceable and
isolate it
> > from PHP. Can you adapt src/dblib/unittests/rpc.c to illustrate the
> > problem?
> >
> > I know that's pushing a lot of work your way. It's not without
cause.
> >>From experience I can tell you that once the problem is set in clear
> > relief with a broken test case, it hardly ever takes more than a
week to
> > fix.
> >
> > Eventually, I'll add generalized stored-procedure calling to bsqldb,
so
> > we can test arbitrary calls and combinations. But that's not going
to
> > happen for a while.
> >
> > --jkl
> >
> > -----Original Message-----
> > From: Kall, Bruce A. [mailto:kall AT mayo.edu]
> > Sent: Tuesday, January 04, 2005 10:58 AM
> > To: Lowden, James K
> > Subject: Re: [freetds] two questions about executing stored
procedures
> >
> >
> > Jim,
> >
> > I downloaded last night's build, freetds-0.64.dev.20050103, and set
it
> > up on my system with the same problem. I added a print statement to
see
> >
> > why it is failing and this is what it prints:
> >
> > Conn is [Resource id #7]<BR>
> > row size [628] buf_element_size[0]
> > php: dblib.c:308: buffer_add_row: Assertion `row_size <=
> > buf->element_size' failed.
> > Aborted
> >
> >
> > Unless you already knew this, the buffer_element_size is the one
coming
> > in to buffer_add_row as zero which causes the assert to fail.
> >
> > If there is anything else I can try, please let me know.
> >
> > Bruce
> >
> >
> > Lowden, James K wrote:
> >
> >>Bruce,
> >>
> >>I don't use Linux or RPMs, or PHP for that matter, so I'm not much
of
> >
> > a
> >
> >>resource for you, I'm afraid.
> >>
> >>Reading your error messages, I would think the situation is roughly
> >>thus:
> >>
> >>PHP is linked to the prior sybdb (4.0).
> >>The installer is about to add the current one (5.0).
> >>The installer wants to remove the old one, finds the dependency, and
> >>stops.
> >>
> >>There's no particular need to remove 4.0 to install 5.0 as far as
> >>FreeTDS goes. If PHP is linked to /usr/lib/libsybdb.so.4.0.0 (and
not
> >>merely /usr/lib/libsybdb.so, which I assume is symbolic link that
will
> >>be overwritten), PHP could continue to use 4.0.
> >>
> >>However, to get the new behavior from FreeTDS, you'll want to
> >
> > deinstall
> >
> >>PHP, too, and relink it with the new FreeTDS.
> >>
> >>AFAICT, your question relates more to your package management system
> >
> > and
> >
> >>which PHP package you want. I've always found that area a little
> >>Byzantine and, fortunately, I've been able to avoid it.
> >>
> >>HTH. I hope you get it working and let us know how you fare.
> >>
> >>--jkl
> >>
> >>-----Original Message-----
> >>From: Kall, Bruce A. [mailto:kall AT mayo.edu]
> >>Sent: Monday, January 03, 2005 9:51 AM
> >>To: Lowden, James K
> >>Subject: Re: [freetds] two questions about executing stored
procedures
> >>
> >>
> >>Jim,
> >>
> >>Sorry to bug you, but have you had a chance to determine what this
> >>conflict is and a possible fix for it?
> >>
> >>Thanks,
> >>Bruce
> >>
> >>
> >>kall AT mayo.edu wrote:
> >>
> >>
> >>>Jim,
> >>>
> >>>I made a rpm from this and tried to install it. When I went to
> >>
> >>install
> >>
> >>
> >>>the rpm it said:
> >>>
> >>>error: Failed dependencies:
> >>> libsybdb.so.4 is needed by (installed) php-mssql-4.3.8-2.1.1
> >>>
> >>>freetds is installing:
> >>>
> >>>/usr/lib/libsybdb.so
> >>>/usr/lib/libsybdb.so.5
> >>>/usr/lib/libsybdb.so.5.0.0
> >>>
> >>>
> >>>but the latest version of php-mssql needs /usr/lib/libsydb.so.4
> >>>(php-mssql-4.3.9).
> >>>
> >>>What am I missing and/or how can I fix this problem?
> >>>
> >>>Thanks,
> >>>Bruce
> >>>
> >>>Lowden, James K wrote:
> >>>
> >>>
> >>>
> >>>>>From: Kall, Bruce A.
> >>>>>Sent: Thursday, December 23, 2004 11:38 AM
> >>>>>
> >>>>>I'm attempting to execute a store procedure on a Sybase system
from
> >>>>
> >>>>
> >>>>php
> >>>>
> >>>>
> >>>>
> >>>>>on my Linux box using freetds. This stored procedure requires a
> >>>>>combination of required parameters, some of which have to be
null.
> >>>>
> >>>>
> >>>>
> >>>>Welcome, Bruce.
> >>>>I believe the very bug you have happened upon is addressed in the
> >>
> >>latest
> >>
> >>
> >>>>Release Candidate:
> >>>>
> >>>>
> >>>>
> >>
> >>
> >
http://ibiblio.org/pub/Linux/ALPHA/freetds/stable/freetds-0.63RC5.tar.gz
> >
> >>>>Please try that and let us know how you fare.
> >>>>--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.






Archive powered by MHonArc 2.6.24.

Top of Page