1. $connection = Propel::getConnection();
  2.  
  3. $query = 'CALL Proc(%s, %s, %s)';   
  4. $query = sprintf($query, $var1, $var2, $var3);
  5.  
  6. $mysqli = $connection->getResource();
  7. if($mysqli->multi_query($query)){
  8.   do{
  9.     if($result = $mysqli->use_result()){
  10.       while($row = $result->fetch_assoc()){
  11.         //
  12.       }
  13.       $result->free();
  14.     }
  15.   } while(($mysqli->next_result()));
  16. }

这里使用了mysqli

 Leave a Reply

(required)

(required)

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

   
© 2011 刘敏的Blog Suffusion theme by Sayontan Sinha