This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

problem writing

Old posts that have not been replied to for several years.
Locked
d
diarmuid

problem writing

Post by diarmuid »

i'm having a problem writing to a mysql database. here's the code, followed by the error.

Code: Select all

proc db:write { id table_write nick uhost } {
   global as_game as_gametype as_server as_map as_players as_location sb_set db trigger_channel

   set sqlhand [mysqlconnect -host $db(host) -user $db(user) -password $db(pass)]

   mysqluse $sqlhand $db(dbase)

$ers` , `map` , `server` , `channel` , `location` ) VALUES (NOW( ), '$sb_set(counter)', '$nick', '$uhost', '$as_game($uhost)', '$as_gametype($uhost)', '$as_players($uhost)v$as_players($uhost)', '$as_map($uhost)', '$as_server($uhost)', '$trigger_channel($uhost)', '$as_location($uhost)')"

   mysqlclose $sqlhand
   return 0
}
the error

Code: Select all

Tcl error [msg:filter]: mysqlexec/db server: Column count doesn't match value count at row 1
i've checked, and re-checked all my tables and i can't find anything wrong. please help!

-diar
O
Ofloo
Owner
Posts: 953
Joined: Tue May 13, 2003 1:37 am
Location: Belguim
Contact:

Post by Ofloo »

check this forum i posted a sample script for this ..

http://forum.egghelp.org/viewtopic.php? ... ight=mysql
XplaiN but think of me as stupid
Locked