fixed DBAL platform query bug