Ahhh-I just noticed you altered the detail one to remove the space and comma
if you do not want a space between the Y or N for multiple rows then fix two things
details needs the comma after the Y or N
Fica := Fica + (If {ETax.tcode} In ["MED", "SS"] Then "Y," else "N,");
footer needs to only subtract 1 (removes the trailing ",")
Shared StringVar Fica := if Fica=0 then "Whatever you want here" else Left(Fica,len(Fica)-1);