CodeIgniter Select Query

前端 未结 10 1001
刺人心
刺人心 2020-12-10 04:37

I have a simple CodeIgniter Active record query to select an ID:

$q = $this -> db
           -> select(\'id\')
           -> where(\'email\', $email         


        
10条回答
  •  孤街浪徒
    2020-12-10 05:28

    public function getSalary()
        {
            $this->db->select('tbl_salary.*,tbl_employee.empFirstName');
            $this->db->from('tbl_salary');
            $this->db->join('tbl_employee','tbl_employee.empID = strong texttbl_salary.salEmpID');
            $this->db->where('tbl_salary.status',0);
            $query = $this->db->get();
            return $query->result();
        }
    

提交回复
热议问题