adding bc queries support
some queries fixed
query filtering added