samedi 8 août 2015

SQL - Order by newid()



I'm trying to select a random row from a table, but there is a column in this table called Rate, I want it to return the row that has a higher rate, and rarely ever return the rows that has a lower rate, is this possible?
Table :
CREATE TABLE _Random (Code varchar(128),Rate tinyint)




Aucun commentaire:

Enregistrer un commentaire