optimize view elements for hiveql