Skip to content

Instantly share code, notes, and snippets.

@uno-de-piera uno-de-piera/Funciona.php Secret
Created Jun 13, 2019

What would you like to do?
$tasks = Task::select('id', 'task_id', 'project_id', 'keyword_id')
->whereIn('id', function ($sub) {
$sub->selectRaw('max(id)')->from('tasks')->groupBy('keyword_id'); // <---- la clave
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.