prova usando la variabile globale $query_string.

query_posts($query_string . 'orderby=rand');