Thank you all for the information. It is obvious that db was not in
scope, so now I call:
set db [ns_db gethandle gamespool]
then I do my queries and everything works fine.
I must apologise for this lack of judgement on my part. It was late
last night when I did this.
Thanks again.
On
Hi all,
I have this in my config file:
ns_section ns/server/games-admin/modules
ns_param nssock $bindir/nssock.so
ns_param nslog $bindir/nslog.so
ns_param nscp $bindir/nscp.so
ns_param nsdb $bindir/nsdb.so
ns_param shared_tcl tcl
ns_section ns/db/drivers
ns_param postgres
So you know, the line:
ns_param gameskillspool Postgres
should read:
ns_param gamespool Postgres
On 01/04/2008, Xavier Bourguignon [EMAIL PROTECTED] wrote:
Hi all,
I have this in my config file:
ns_section ns/server/games-admin/modules
ns_param nssock $bindir/nssock.so
ns_param
That's a problem about variables scope, Xavier.
the line: set row [ns_db select $db select * from tadminoptype;]
requires the variable $db to be set.
That's done by the line: set db [ns_db gethandle gamespool]
So to make the query work, you only need to add the line set db ..
before the
How are db.tcl and admin.tcl called?
The normal way of using ns_db is simply to get a handle in the page
(ADP, Tcl or registered proc) that you need it on. Not in some other
file like your db.tcl.
Bas.
On 02/04/2008, at 7:51 AM, Xavier Bourguignon wrote:
Hi all,
I have this in my
I have this in my config file:
ns_section ns/server/games-admin/modules
ns_param nssock $bindir/nssock.so
ns_param nslog $bindir/nslog.so
ns_param nscp $bindir/nscp.so
ns_param nsdb $bindir/nsdb.so
ns_param shared_tcl tcl
ns_section ns/db/drivers
ns_param
Your pool is called gameskillspool and your in /db/pool you just have
gamespool.
Respectfully,
Darren Ferguson
Xavier Bourguignon wrote:
Hi all,
I have this in my config file:
ns_section ns/server/games-admin/modules
ns_param nssock $bindir/nssock.so
ns_param nslog $bindir/nslog.so