Re: insert into mysql

From: Date: Tue, 30 Jan 2001 15:16:15 +0000
Subject: Re: insert into mysql
References: 1 2  Groups: php.db 
Request: Send a blank email to php-db+get-6267@lists.php.net to get a copy of this message
I found the problem. I didn't give myself write access to the database :} ----- Original Message ----- From: "Darryl Friesen" <Darryl.Friesen@usask.ca> To: <php-db@lists.php.net> Sent: Monday, January 29, 2001 8:32 AM Subject: Re: [PHP-DB] insert into mysql > > > > > $sql = "INSERT INTO ecomm (ID,part) VALUES > > > > > ('$sid','$spp')"; > > > > > > Another thought: Are ID and part character data of some sort? If not > (i.e. > > > if ID is an int) then remove the single quotes. > > > > > A trivial point this, but if you insert values in ' into a mysql int > > column then MySQl still treats it as intended. THey aren' necessary for > > int columns, but it is acceptable to have them there > > Thanks for pointing that out Tom. That's a good bit of info to tuck away > for later. > > We've been using MSSQL Server 7 here quite a bit lately, and it isn't nearly > as forgiving. :( > > - Darryl > > ---------------------------------------------------------------------- > Darryl Friesen, B.Sc., Programmer/Analyst Darryl.Friesen@usask.ca > Education & Research Technology Services, > http://gollum.usask.ca/ > Department of Computing Services, > University of Saskatchewan > ---------------------------------------------------------------------- > "Go not to the Elves for counsel, for they will say both no and yes" > > > > -- > PHP Database Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net > For additional commands, e-mail: php-db-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net > >

« previous php.db (#6267) next »