只想使用 codeigniter 从数据库中选择不同的值,但它返回重复值。您能否检查一下我的以下代码有什么问题:
$this->db->distinct('country');
$this->db->where('id',$id);
$query = $this->db->get('table_name');
最佳答案
可以这样试试吗?
$this->db->distinct();
$this->db->select('country');
关于php - 无法使用 codeigniter 选择不同的值,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25645191/