freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: "James K. Lowden" <jklowden AT schemamania.org>
- To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
- Subject: Re: [freetds] connection pooling
- Date: Wed, 27 Oct 2004 23:27:28 -0400
Shaun Craig <s.craig AT andronics.com> wrote:
> I currenly have a C program
> that can query and insert to MS SQL on a windows machine, now i want to
> set up connection pooling but dont know how. I've set up the
> freetds.conf and pool.conf files ok and can tdspool myspool and start
> the server, i dont know how to point my C program at the server?
In pool.conf, you define a port that the pool server listens to, something
like this:
[mypool]
user = webuser
password = secret
database = ebiz
server = fooserv
max pool conn = 7
port = 5555
In freetds.conf, you declare a server entry pointing to it:
[pool]
host = localhost #if that's where it's running
port = 5555
tds version = 4.2
Then, you connect to [pool] per usual:
DBPROCESS *db = dbopen (login, "pool");
HTH.
--jkl
-
[freetds] connection pooling,
Shaun Craig, 10/27/2004
- Re: [freetds] connection pooling, Michael Peppler, 10/27/2004
-
Re: [freetds] connection pooling,
James K. Lowden, 10/27/2004
- Re: [freetds] connection pooling, Shaun Craig, 10/28/2004
- <Possible follow-up(s)>
- [freetds] Connection Pooling, Shaun Craig, 10/29/2004
-
RE: [freetds] Connection Pooling,
Lowden, James K, 10/29/2004
- Re: [freetds] Connection Pooling, Shaun Craig, 10/29/2004
- RE: [freetds] Connection Pooling, Lowden, James K, 10/29/2004
Archive powered by MHonArc 2.6.24.