Re: Fw: tricky RAND() function...

2001-07-20 Thread Werner Stuerenburg
- Original Message - > From: Derick Dorner > To: [EMAIL PROTECTED] > Sent: Tuesday, July 17, 2001 3:11 PM > Subject: tricky RAND() function... > I am using MySQL 3.22, and need to know how to randomly select a record, therefore I >can't just use the ORDER BY RAND(

Re: Fw: tricky RAND() function...

2001-07-20 Thread Werner Stuerenburg
L PROTECTED] > Sent: Tuesday, July 17, 2001 3:11 PM > Subject: tricky RAND() function... > I am using MySQL 3.22, and need to know how to randomly select a record, therefore I >can't just use the ORDER BY RAND() clause, because of my version. so i do this: > SELECT field1,field2*0

Fw: tricky RAND() function...

2001-07-20 Thread Derick Dorner
- Original Message - From: Derick Dorner To: [EMAIL PROTECTED] Sent: Tuesday, July 17, 2001 3:11 PM Subject: tricky RAND() function... I am using MySQL 3.22, and need to know how to randomly select a record, therefore I can't just use the ORDER BY RAND() clause, because

tricky RAND() function...

2001-07-17 Thread Derick Dorner
I am using MySQL 3.22, and need to know how to randomly select a record, therefore I can't just use the ORDER BY RAND() clause, because of my version. so i do this: SELECT field1,field2*0+RAND() as rand_col FROM TableName WHERE field3=5 ORDER BY rand_col; --according to paul dubois' book I have