Ordering fields, also remove unnecesary fields