SQL SELECT RANDOM ROW

Select row secara random dengan MySQL:

SELECT column FROM table
ORDER BY RAND()
LIMIT 1

Select row secara random dengan SQL Server:

SELECT TOP 1 column FROM table
ORDER BY NEWID()

Post a Comment

0 Comments