I am trying to retrieve the second result of this query (which works successfully):
$assist_stats = App\Stat::whereRaw('assists = (select max(`assists`) from stats)')->get()->first();
With this modified code:
$assist_stats2 = App\Stat::whereRaw('assists = (select max(`assists`) from stats)')->get([1]);
But I get this error:
SQLSTATE[42S22]: Column not found: 1054 Unknown column '1' in 'field list' (SQL: select `1` from `stats` where assists = (select max(`assists`) from stats))
How would I retrieve the second result from the query?
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire