improve loadRandom
make mongo more compatible with SQL