sample-query warks, without db connection