fix performance queries