Zend_Db_Table的$where

$patient=new patient();

 $db=$patient->getAdapter();

$where=$db->quoteInto('patientname like ?',"%".trim(GetSQLValueString($_POST['name'],"text"))."%");

$where=$where.$db->quoteInto('and sex=?',$_POST['sex']);

$where=$where."and age between 0 and 5";

$this->view->patients=$patient->fetchAll($where,$order,$count,$offset)->toArray();

你可能感兴趣的:(Zend_Db_Table的$where)