Issue refs #1307: fixed bug with schema name in queries (mapping)