Skip to content

limit is not works in the first time #176

@yftzeng

Description

@yftzeng

Branch: dev-develop

Note: use the same limit code twice.

$rs = ORM::for_table('position')
    ->limit(1)
    ->find_array();

var_dump(ORM::get_last_query());
var_dump(count($rs));

$rs = ORM::for_table('position')
    ->limit(1)
    ->find_array();

var_dump(ORM::get_last_query());
var_dump(count($rs));

The result:

string(22) "SELECT * FROM position"
int(89)
string(32) "SELECT * FROM `position` LIMIT 1"
int(1)

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions