Closed Nilanjan011 closed 1 day ago
I've reproduced this using the FM facade directly.
A few things I'm noticing with your example, though....
If you're searching for an ID you should only be getting one record back. You shouldn't need to paginate something like that.
I'd recommend using a model if possible rather than doing a query directly using the query builder if possible. You get more features than with the query builder, and paginating does work with models correctly.
As an alternative for your query, I'd recommend something like the following (pretending you're doing a query for the model "Person")
$pet = Person::find($id);
or if you really don't want to have a model for whatever reason...
$data = FM::table('table')->find($id);
Closing this as stale
$data = FM::table('table')->where('id',$id)->paginate(10);
Error showing: Undefined index: aggregate
also join() not working