You don't need an extension

March 29, 2004 by Retha Staden
Use the following statement in the header of your page - leave out the LIMIT 1 if you want them all to show, in random order - use LIMIT 1 if you want one villa record to show, randomly: $query_dbname = "SELECT * FROM dbname ORDER BY RAND() LIMIT 1"; Good luck! R

sorry - the previous answer was for PHP MySQL

March 29, 2004 by Retha Staden

Try NEWID() if you use MS SQL

March 30, 2004 by Rick Heidrick

Here is a good bit of information concerning your requirement:
http://www.sqlteam.com/item.asp?ItemID=8747

Rick

NEWID()

January 24, 2005 by Matt Penn
Using the NEWID() in my SQL Statement was the only one of these suggestions that worked. Simple! Everything else seems to involve a ton of extra code.