[eluser]Unknown[/eluser]
//The CODE:
function adminis()
{
$this->load->database();
$this->load->library('pagination');
$this->load->library('table');
$config['base_url']= 'http://localhost/index.php/site/adminis';
$config['total_rows']= $this->db->get('solicit')->num_rows();
$config['per_page']= 4;
$config['num_links']= 20;
$this->pagination->initialize($config);
$sql='SELECT * FROM solicit, respost WHERE solicit.id_solicit = respost.id_solicit';
$respost['respost']=$this->db->get($sql,$config['per_page'],$this->uri->segment(3));
$this->load->view('logged_in_adminisr',$respost);
}
//And the error is:
A Database Error Occurred
Error Number: 1064
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '* FROM solicitud, respuestas WHERE solicitud.id_solicitud = respuestas.id_solici' at line 2
SELECT * FROM (`SELECT` * FROM solicit, respost WHERE solicit.id_solicit = respost.id_solicit) LIMIT 4
// But the sql statement is correct and validate the sql client knows someone who gives this error