Re: Oracle INSERT

From: Date: Thu, 28 Mar 2002 17:27:16 +0000
Subject: Re: Oracle INSERT
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-18003@lists.php.net to get a copy of this message
I'm not sure.. but try the folowing statements: $sql = "INSERT INTO tblTest VALUES(1,'Test One') INSERT INTO tblTest VALUES(2,'Test Two') INSERT INTO tblTest VALUES(3,'Test Three') "; (just repeating the insert statement... ) or (repeating the insert statement, separated by semicolon...) $sql = "INSERT INTO tblTest VALUES(1,'Test One'); INSERT INTO tblTest VALUES(2,'Test Two'); INSERT INTO tblTest VALUES(3,'Test Three'); "; Chris Andrew wrote: > Hi, > > This is probably more of a topic for the Oracle groups - however: > > This gives me an error: > $c1 = ocilogon("chris","chris01"); > $sql = "INSERT INTO tblTest VALUES(1,'Test One'),(2,'Test Two')"; > $stat= ociparse($c1,$sql); > > It would appear my INSERT syntax is illegal under Oracle. > > Qu: How can I INSERT multiple rows with ONE statement? > > Thanks in advance. > Chris

« previous php.db (#18003) next »