[eluser]ladooboy[/eluser]
I've upgraded from CI2.0.2 to CI2.1.3 and noticed that all queries with an EMPTY string or FALSE value for limit would get a "limit 0" on the end of every query.
Code:
public function limit($value, $offset = '')
{
$this->ar_limit = (int) $value;
if ($offset != '')
{
$this->ar_offset = (int) $offset;
}
return $this;
}
The reason is this line
Code:
$this->ar_limit = (int) $value;
If you pass FALSE or EMPTY STRING it will convert the $value to a 0 and limit every query to zero results. Same problem for offset.
I've removed the (int) conversion for LIMIT and OFFSET for now, which has fixed the issue.