Select, count and where using codeigniter and mysql

前端 未结 4 1152
被撕碎了的回忆
被撕碎了的回忆 2021-01-12 07:31

I have two table as follow:

- tblSaler

    SalerID  |  SalerName | 
    ----------------------|
    1        |  sothorn   |
    ----------------------|
            


        
4条回答
  •  离开以前
    2021-01-12 08:23

       ## try this ##
       $this->db->select($column_name);
        $this->db->where($column_name,$type);
        $q=$this->db->get($table_name);
        $count=$q->result();
        return count($count);'
    

提交回复
热议问题