required columns calculation