Random Row

  • Thread starter Thread starter Luis E Valencia
  • Start date Start date
Count the rows, generate a random # from 1 to X
Get row x.
Mind you you really should get the unique ID's, put them into an array/list,
generate the random from there.
 
if you are using sql server

select top 1 * from mytable
order by newid()

I think you should be able to find plenty of articles on how to display data from a database.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top