correcting ia qry type