我可以简单地限制mysql中表字段的字符大小
SELECT NID,LEFT(BODY, 10) AS text FROM tablename
但是我如何在codeigniter Active Record
尝试此代码时获得相同的结果
$this->db->select('NID, LEFT(BODY,10)');
$query = $this->db->get_where('tablename');
但不工作
有可能做到codeigniter Active Record
吗?