db->select('*'); $this->db->from('degree'); $this->db->where(array('status'=>1)); $query = $this->db->get(); //echo $this->db->last_query();exit; return $query; } function get_deg($id) { $this->db->select('*'); $this->db->from('degree'); $this->db->where(array('status'=>1,'id'=>$id)); $query = $this->db->get(); //echo $this->db->last_query();exit; return $query; } function get_dep() { $this->db->select('id,name'); $this->db->from('department'); $this->db->where(array('status'=>1)); $query = $this->db->get(); //echo $this->db->last_query();exit; return $query; } }