Answers for "unique in to field laravel"

PHP
1

get unique values in laravel

$users = User::select('name')->distinct()->get();
Posted by: Guest on February-19-2021
1

laravel set field unique

Schema::table('manufacturers', function($table)
{
    $table->string('name')->unique(); 
});
Posted by: Guest on March-31-2020

Code answers related to "unique in to field laravel"

Browse Popular Code Answers by Language