Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

get random data laravel

// 5 indicates the number of records
User::inRandomOrder()->limit(5)->get();
// get one random record
User::inRandomOrder()->first();
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #random #data #laravel
ADD COMMENT
Topic
Name
3+2 =