Procedure does not run in codeigniter

Asked

Viewed 74 times

0

function renovarEmprestimos($matricula, $livro){
$this->db = $this->load->database('biblioteca', TRUE);
$query = $this->db->query("EXEC J_renovarlivroweb '$matricula', '$livro', '1' ");
//$this->db->last_query();
return $query->result();
}

My function was functional but now I can no longer perform EXEC by calling the function. However, if you call $this->db->last_query(); and put EXEC in the sql base works right. How can I run this exec by calling the function?

  • 1

    Which SGDB you are using?

  • SQL SERVER 2008

  • try like this, SELECT J_renovarlivroweb('$matricula', '$livro', '1')

  • @David had the following error: Error Number: 195 'J_renovarlivroweb' is not a recognized Function name. SELECT J_renovarlivroweb('14150055', '000000040351', '1') Filename: models/Biblioteca_model.php Line Number: 75

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.