Skip to Content.
Sympa Menu

freetds - RE: Mysterious segfaults PHP+unixODBC+freetds

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Bj�rn Lantz" <bjorn.lantz AT easyt.com>
  • To: freetds AT franklin.oit.unc.edu
  • Subject: RE: Mysterious segfaults PHP+unixODBC+freetds
  • Date: Tue, 4 Jun 2002 13:45:23 -0400


I tried conversion both on a "uniqueidentifiers" field and on a currency
field. The problem remains :-( and consequence of 'converting' is that the
first, and only first, result rows currency field is truncated one
character in the beginning like "885" instead of "7885". Hmmm...

The strangest thing though is that it works 50% of the times, and like I
wrote in my original posting, the problem only appears when I connect
towards a remote sql server. I have an equally configured machine at the
remote site, and that one works towards the local (for that machine) sql
server.

I'm still for timeout problems.

BTW I just found that every time it crashes I have a logging in the
freetds log that looks like this :
Received packet @ 2002-06-04 19:40:37
0000 fd 20 00 00 00 00 00 00 00 |ý .......|

> This can happen in PHP when you select binary type fields (e.g.
> uniqueidentifiers) - the conversion code doesn't always work, and can depend
> on the actual values - it converts it to text, such that when it works, you
> get a character string equivalent - which may of course not be a valid
> string in PHP. Atleast, I believe that is what the problem is. The best
> thing to do is convert(char(36),your_unique_id_field) in the query. The
> same thing (I think) happens on currency types.
>
> BTW - this isn't a freetds issue - it's PHP.
>
> hth,
> Dave.




Archive powered by MHonArc 2.6.24.

Top of Page