remove double query creation