Order all mysql data by rand then order it by column -


i have 1000 records querying , ordering random. each record has business type want order random businesstype. query :

$sqlquery = "select * businesses postcode regexp '^" . $pcode . "[0-9]' , businessid not in (select businessid telesales.notinterested now() between dateofcall , (dateofcall + interval 42 day)) order rand() limit 500"; 

if rand(), businesstype random still, , if try group businesstype after rand doesnt give results. ideas?


Comments

Popular posts from this blog

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12:test (default-test) on project.Error occurred in starting fork -

windows - Debug iNetMgr.exe unhandle exception System.Management.Automation.CmdletInvocationException -

configurationsection - activeMq-5.13.3 setup configurations for wildfly 10.0.0 -