Closed andrez89 closed 1 year ago
There are two ways:
1 - The regular Eloquent way is to use the count()
function. This works fine with Eloquent FileMaker as well. Something like MyModel::count()
would give you the total record count. This can work from any query just like it does with base Eloquent, so MyModel::where('my_field', 'my value')->count()
works as it normally would with Laravel.
2 - The FM
facade lets you do more raw-ish queries. You get the parsed JSON results back from the data API like you would from a regular data API call, from which you can read the totalRecordCount
property as normal.
I'd definitely recommend option 1.
I've been looking at the docs and sources, but I cannot find hot to retrieve informations such as 'totalRecordCount' from a get records request.
Is there a way to access this information?