Re: [PHP-DB] multiple queries in a row

2002-07-02 Thread Casey Allen Shobe

On Thursday 27 June 2002 02:19 pm, Mattia wrote:
 I would like to make multiple queries in a single mysql_query(...)
 statement!! Like in the mysql client given with the distribution, separated
 by a ; or a \g !!!
 How can I???

You should be able to use it exactly the same.

$foo = mysql_query('
select  something
fromsomewhere;

select  something_else
fromsomewhere_else;
', $link_id);

-- 
Casey Allen Shobe / Network Security Analyst  PHP Developer
SecureWorks, Inc. / 404.327.6339 x169 / Fax: 404.728.0144
[EMAIL PROTECTED] / http://www.secureworks.net
Content is my own and does not necessarily represent my company.

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




Re: [PHP-DB] multiple queries in a row

2002-07-02 Thread Jason Wong

On Wednesday 03 July 2002 04:36, Casey Allen Shobe wrote:
 On Thursday 27 June 2002 02:19 pm, Mattia wrote:
  I would like to make multiple queries in a single mysql_query(...)
  statement!! Like in the mysql client given with the distribution,
  separated by a ; or a \g !!!
  How can I???

 You should be able to use it exactly the same.

 $foo = mysql_query('
 selectsomething
 from  somewhere;

 selectsomething_else
 from  somewhere_else;
 ', $link_id);

IIRC php only allows you to pass a single query at a time to mysql.

-- 
Jason Wong - Gremlins Associates - www.gremlins.com.hk
Open Source Software Systems Integrators
* Web Design  Hosting * Internet  Intranet Applications Development *


/*
Every program is a part of some other program, and rarely fits.
*/


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php