Skip to Content.
Sympa Menu

freetds - RE: [freetds] Possible bug: DBD::Sybase + current FreeTDS + selec tall_hashref

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Gad Hayisraeli" <gadh AT vmanage.com>
  • To: <freetds AT lists.ibiblio.org>
  • Subject: RE: [freetds] Possible bug: DBD::Sybase + current FreeTDS + selec tall_hashref
  • Date: Tue, 4 Feb 2003 12:25:06 +0200

i'm not familiar with the freetds code , so if this can help to boost
performance, i'd like to ask someone to do this

thanks

Gad

> -----Original Message-----
> From: freetds-admin AT lists.ibiblio.org
> [mailto:freetds-admin AT lists.ibiblio.org]On Behalf Of Thompson, Bill D
> (London)
> Sent: ?a 04 oaoaao 2003 11:56?
> To: 'freetds AT lists.ibiblio.org'
> Subject: RE: [freetds] Possible bug: DBD::Sybase + current FreeTDS +
> selec tall_hashref
>
>
> Hi,
>
> I suspect this problem is down to my re-working of the "results processing"
> some while back.
> I had to rework both the tds_process_results() functions and also the
> ct_results() function.
>
> In this, I took advice from the Sybase ct-library manual, in which it states
> (in the ct_results routine description):
>
> "An application will not receive format results unless the Client-Library
> CS_EXPOSE_FMTS property is set to CS_TRUE."
> I impmemented this, and the code in ct_config() to enable this property to
> be toggled.
> I assumed the default setting of this property to be CS_FALSE, although
> looking over the manuals again, I cant find anything that supports this
> assumption (or, to be fair, it's converse). Also, It looks like I didn't add
> the code to ct_con_props(), which also allows this property to be toggled.
> One or two things need to be done:
> 1) set the default for this property to be CS_TRUE, instead of CS_FALSE
> 2) implement the code in ct_con_props() to allow this property to be
> toggled. It may be the case that a call to this function is being "ignored"
> in the ct_con_props() function.
>
> HTH
> Bill
>
>
>
> > -----Original Message-----
> > From: Michael Peppler [SMTP:mpeppler AT peppler.org]
> > Sent: 04 February 2003 01:08
> > To: freetds AT lists.ibiblio.org
> > Subject: Re: [freetds] Possible bug: DBD::Sybase + current FreeTDS +
> > selectall_hashref
> >
> > On Mon, 2003-02-03 at 11:19, Martin Schroth wrote:
> > > Hi,
> > >
> > > DBI gets the following error if there are no rows to return:
> > > Can't get DBI::st=HASH(0x...)->{NAME}: unrecognised attribute
> > >
> > > Example:
> > > my $stmt = "SELECT 1 FROM test WHERE 1=0"
> > > my $hash = $dbh->selectall_hashref($stmt,1);
> >
> > This works fine when used with the Sybase libs, so I suspect a slight
> > difference in return values.
> >
> >
> >
> > > -> execute for DBD::Sybase::st (DBI::st=HASH(0x81f9964)~0x81f9940)
> > > thr#804b3c0
> > > syb_st_execute() -> ct_command() OK
> > > syb_st_execute() -> ct_send() OK
> > > st_next_result() -> ct_results(4046) == 1
> >
> > And this is the difference. With the Sybase libs I get:
> >
> > syb_st_execute() -> ct_command() OK
> > syb_st_execute() -> ct_send() OK
> > st_next_result() -> ct_results(4040) == 1
> > ct_res_info() returns 1 columns
> > ct_describe(0): type = 8, maxlen = 4
> > describe() -> col 0, type 8, realtype 8
> > describe() retcode = 1
> > st_next_result() -> lasterr = 0, lastsev = 0
> >
> > FreeTDS returns no data at all, whereas you should still get the column
> > description even if there are no rows returned.
> >
> > Michael
> > --
> > Michael Peppler Data Migrations, Inc.
> > mpeppler AT peppler.org http://www.mbay.net/~mpeppler
> > Sybase T-SQL/OpenClient/OpenServer/C/Perl developer available for short or
> >
> > long term contract positions - http://www.mbay.net/~mpeppler/resume.html
> > _______________________________________________
> > FreeTDS mailing list
> > FreeTDS AT lists.ibiblio.org
> > http://lists.ibiblio.org/mailman/listinfo/freetds
>
> _______________________________________________
> FreeTDS mailing list
> FreeTDS AT lists.ibiblio.org
> http://lists.ibiblio.org/mailman/listinfo/freetds
>
>







Archive powered by MHonArc 2.6.24.

Top of Page