laravel remove duplicates sql code example Example: laravel collection remove duplicates $unique = $collection->unique();