This query, return this error.
operator does not exist: text = integer LINE 2: from mas_book ) as outp where outp.authors = 2 ^ HINT: No operator matches the given name and argument type(s). You might need to add explicit type casts
public function authors($ids)
{
$query = "select count(authors) from (select distinct regexp_split_to_table(author, E',') as authors
from mas_book ) as outp where outp.authors = ".$ids;
$result = $this->db->query($query);
return $result->result();
}