relation attribute, reformat code