How to get some randomized concats based on 2 columns from 1 table?

Posted by Nils Riedemann on Stack Overflow See other posts from Stack Overflow or by Nils Riedemann
Published on 2010-03-17T08:15:47Z Indexed on 2010/03/17 8:21 UTC
Read the original article Hit count: 217

Filed under:
|
|

Hey folks,

i have a large user Database (13k+), and for some reason i need to create random names. The users table has "first_name" and "last_name". Now i want to have 10 concats of full_name and last_name of two completely random rows. Is that even possible with SQL?

My other idea was just to create a full_names and last_names table … but that would'nt be as much challenging.

Oh, and it should not take up too much performance :) (so order by rand() is not an option ;))

© Stack Overflow or respective owner

Related posts about sql

Related posts about random