Skip to Content.
Sympa Menu

freetds - Re: [freetds] Connection support only one query at a time

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Frediano Ziglio <freddy77 AT gmail.com>
  • To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] Connection support only one query at a time
  • Date: Fri, 22 May 2009 17:56:25 +0200

Il giorno ven, 22/05/2009 alle 17.45 +0200, Matthias Cramer ha scritto:
> Hi James
>
> You're my hero of the day ... I now open two connections at the beginning
> of my script. One to the outer loop and one for the inner querries.
>
> Execution time of my script is now down to 17s from >90s ... great.
>
> Thanks again for the enlightenment.
>
> Regards
>
> Matthias
>

If you use ODBC (like DBD::ODBC) you can even use cursors.
Just use cursor for outer loop and normal queries for inner ones.
Also consider using other types queries or handle code all in server.
Honestly I had to use client side cursors only a time in my life, in
this case processing every row and updating the same row on some
complicated conditions (where computation was not possible on server).

Regards
Frediano







Archive powered by MHonArc 2.6.24.

Top of Page