Answers for "php ci get query"

PHP
1

codeigniter raw query

$sql="Select * from my_table where 1";    
    $query = $this->db->query($SQL);
    return $query->result_array();
Posted by: Guest on September-03-2020
0

codeigniter 3 update

$data = array(
        'title' => $title,
        'name' => $name,
        'date' => $date
);

$this->db->where('id', $id);
$this->db->update('mytable', $data);
Posted by: Guest on November-06-2020

Browse Popular Code Answers by Language