Re: SQL Syntax error in DBI::Informix
Posted in 2000
Topics: Security, Permissions & Auditing
On Wed, 12 Jul 2000, Obnoxio The Clown wrote: > What's the value of $table? $table = "userinfo"; which exists under my database. Actually, the problem has since been solved. Thanks for your attention. Paul King > > From: "paul@conxsysinc.com" <paul@conxsysinc.com> > > > >My script connects with the Informix DB server, but it doesn't like my > >INSERT > >statement (below). This code below is supposed to store a new user into > >a database. > > > >print "DEBUG: OK, so we are adding $userd with password > > $passd and server $host at port $port\\n"; > >my $sth = $dbh->prepare(" > > INSERT INTO $table > > VALUES ($userd, $passd, $host, $port) > > ") > > or die "Can't prepare SQL statement to INSERT data\\n"; > > > >The error message it gives is: > >DBD::Informix::db prepare failed: SQL: -201: A syntax error has > >occurred. at > >./adduser line 53. > > > >(and yes, I know I should change the name, but later). This is not a > >program where > >users are added to the System with accounts. It is for a different > >service. > > > >If anyone can help, thanks a lot > > > >Paul King > > > > > > ________________________________________________________________________ > Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com >