RE: [PHP] Multiple inserts as a single string?

2005-06-02 Thread Jared Williams
> > Thanks Richard that makes it clear. > > Thomas > > Hello Thomas, > > Thursday, June 2, 2005, 10:20:11 AM, you wrote: > > T> I have a bit of strange question: when wanting to insert multiple > T> records into the db, instead of looping through the set > and executing > T> mysql_query (wh

RE: [PHP] Multiple inserts as a single string?

2005-06-02 Thread Thomas
Thanks Richard that makes it clear. Thomas -Original Message- From: Richard Davey [mailto:[EMAIL PROTECTED] Sent: 02 June 2005 12:43 PM To: php-general@lists.php.net Subject: Re: [PHP] Multiple inserts as a single string? Hello Thomas, Thursday, June 2, 2005, 10:20:11 AM, you wrote

RE: [PHP] Multiple inserts as a single string?

2005-06-02 Thread Thomas
Message- From: Shaw, Chris - Accenture [mailto:[EMAIL PROTECTED] Sent: 02 June 2005 12:20 PM To: Thomas; php-general@lists.php.net Subject: RE: [PHP] Multiple inserts as a single string? Thomas, If you're inserting alot of rows, (eg millions) then concating them and calling the db

Re: [PHP] Multiple inserts as a single string?

2005-06-02 Thread Rory McKinley
Richard Davey wrote: > > Sure.. mysql_query doesn't support more than one query in the sql > statement. > At the risk of being thick, does the OP not mean something like this: INSERT INTO blah VALUES (value1, value2), (value3, value4) versus INSERT INTO blah VALUES (value1, value2) ne

RE: [PHP] Multiple inserts as a single string?

2005-06-02 Thread Shaw, Chris - Accenture
-Original Message- From: Thomas [mailto:[EMAIL PROTECTED] Sent: 02 June 2005 12:20 To: Shaw, Chris - Accenture Cc: php-general@lists.php.net Subject: RE: [PHP] Multiple inserts as a single string? * This e-mail has been received by the Revenue Internet

Re: [PHP] Multiple inserts as a single string?

2005-06-02 Thread Richard Davey
Hello Thomas, Thursday, June 2, 2005, 10:20:11 AM, you wrote: T> I have a bit of strange question: when wanting to insert multiple T> records into the db, instead of looping through the set and T> executing mysql_query (which will then call the db n times), is it T> not better to concat a string

RE: [PHP] Multiple inserts as a single string?

2005-06-02 Thread Shaw, Chris - Accenture
t was loop, you know exactly what went wrong by outputing the current insert statement. C. -Original Message- From: Thomas [mailto:[EMAIL PROTECTED] Sent: 02 June 2005 10:20 To: php-general@lists.php.net Subject: [PHP] Multiple inserts as a single string? Hi there, I have a bit of st

[PHP] Multiple inserts as a single string?

2005-06-02 Thread Thomas
Hi there, I have a bit of strange question: when wanting to insert multiple records into the db, instead of looping through the set and executing mysql_query (which will then call the db n times), is it not better to concat a string with all the insert statements and let mysql handle the insert

Re: [PHP] multiple inserts into a db

2005-05-19 Thread Richard Lynch
On Wed, May 18, 2005 9:47 pm, mayo said: > $ses_basket_items is the total number of items > $orderID = the orderID which these items are a part of > $ses_basket_id = is the itemID number Which item ID number? Cuz, like, you've got FOUR different itemID numbers. Something isn't making sense here

[PHP] multiple inserts into a db

2005-05-18 Thread mayo
I'm putting ordered items into a db. The information is stored in session variables. Session_variable_with_itemID_has(1001,1002,1003,1004) however when inserted into the db only 0,0,0,0 is recorded. Assuming that this was the 40th recorded order the table should look like this TABLE: orderedI

Re: [PHP] Multiple Inserts

2001-03-09 Thread Phil Driscoll
MAIL PROTECTED]> Date: Friday, March 09, 2001 12:31 PM Subject: [PHP] Multiple Inserts >Hi, > >I am trying to do some multiple inserts using the following code but it >doesn`t seem to work, it inserts the first one but then the second is >inserted as blank. Where the value being

Re: [PHP] Multiple Inserts

2001-03-09 Thread Website4S
In a message dated 09/03/2001 12:38:08 GMT Standard Time, [EMAIL PROTECTED] writes: << Whoa, you're mixing apples with oranges. Try: $db = mysql_select_db($dbase, $connection); $SQLStatement = "INSERT INTO Members (Email) VALUES ('" . $GetEmails[$a] . "')"; //removed the 'or die' portion

Re: [PHP] Multiple Inserts

2001-03-09 Thread CC Zona
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] wrote: > $SQLStatement = "INSERT INTO Members (Email) VALUES ('".$GetEmails[$a] ."')" > or die ("Problem"); > $db = mysql_select_db($dbase, $connection); > $SQLResult = mysql_query($SQLStatement); Whoa, you're mixing apples with oranges. Try:

[PHP] Multiple Inserts

2001-03-09 Thread Website4S
Hi, I am trying to do some multiple inserts using the following code but it doesn`t seem to work, it inserts the first one but then the second is inserted as blank. Where the value being passed is $Emails="[EMAIL PROTECTED], [EMAIL PROTECTED]"; Anyone know what might be going wrong, or perh