Is there any way I can get MySQL records, where the is_new field is = 1, but when there are no records with the is_new = 1 field, I want the query to do an ORDER BY rand () is it possible?
In practice, every time I make a select, I want to bring 5 clients, using order by rand, but when I have new records (and for that the is_new field, the client table gets 1) I want it to bring 5 of those last records, so when the records are displayed his flag changes to 0 and the next query comes only from rand
Thank you