replaced array with switch for diaplaying column values