select distinct laravel
snippet in php

select distinct laravel

user3401

$items = DB::table('item')->select('item_name')->distinct()->get();

eloquent get distinct

user5576

$ad->getcodes()->distinct('pid')->count('pid');