Skip to Content.
Sympa Menu

freetds - Rép. : [freetds] Re: update query with Freetds

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Laurent DAVID" <ldavid AT tf1.fr>
  • To: <freetds AT franklin.oit.unc.edu>
  • Subject: Rép. : [freetds] Re: update query with Freetds
  • Date: Wed, 06 Sep 2000 14:15:41 +0200

Hello,
 
No, the update queries are quite short (less thant 100 characters).
 
The exact feature is :
- the update is done into the database
- the apache process gets a segmentation error logged into
error_log, and then traps, which causes the browser to get
no response from the apache server.
 
Furthermore, here are the installation steps we've followed :
 
1. Freetds compilation :
./configure --prefix=/usr/local/freetds/ --enable-msdblib --with-tdsver=4.2
 
2. PHP3 compilation
./configure '--with-apache=../apache_1.3.12' '--with-gd' '--with-ttf' '--with-xml' '--with-zlib' '--with-sybase=/usr/local/freetds/' '--enable-track-vars'
 
3-Apache installation
./configure --prefix=/usr/local/apache/ --activate-module=src/modules/php3/libphp3.a
 
And then modify the interfaces file of freetds to point to our database server.
 
Does anybody have an idea ?
Regards

>>> roger AT firedrake.org 06/09/2000 13:20:41 >>>
On or about Wed, Sep 06, 2000 at 07:10:42AM +0000, L. DAVID typed:
>Hello,
>
>I'm a newbie into this community, and currently working
>on a project trying to use freetds 4.2 with PHP 3 running
>on Solaris with Apahce, to send some queries to a MS SQL 7 database
>running on NT.
>
>All the select like requests are running well, but
>Apache seems to trap when we are trying an update
>request on a table.
>
>Is this a bug, or is there something special to configure
>when building freetds ?

I'm also a newbie here... but this may be something that bit me,
which I've semi-solved. (There are archive messages that seem
to be related, though it's not entirely clear to me yet; and alas,
my employers disapprove of my spending the _entire_ day reading
about tools rather than working with them.)

Are the update queries longer than 512 characters, while the
selects are shorter? MS-SQL 7 seems to have problems with queries
sent in more than about two packets, and closes the data stream -
and FreeTDS hangs waiting for a response.

Try extending the packet length in write.c, where it's set to
512 at the moment - might also be worth raising BUFSIZ to match.

Something I haven't seen discussed here is spurious NULs - I'm
using DBD::Sybase on top of FreeTDS to talk to MS-SQL7, and
most of the fields returned by SELECTs have trailing NULs.
Naturally this wouldn't be a problem with C, but Perl quite
happily retains and forwards the NULs, thus confusing the web
browser... has anyone else seen this, and is there a
recommended fix?

Roger

--
Roger Burton West roger AT firedrake.org
ACTING IN A PRIVATE CAPACITY
Senior Internet Developer Torrington Interactive

---
You are currently subscribed to freetds as: [ ldavid AT tf1.fr]
To unsubscribe, forward this message to leave-freetds-115034P AT franklin.oit.unc.edu



  • Rép. : [freetds] Re: update query with Freetds, Laurent DAVID, 09/06/2000

Archive powered by MHonArc 2.6.24.

Top of Page