in reply to Strings overwrite themselves in print command

It seems highly likely that the variables you are printing have trailing carriage returns. Try stripping these before printing. eg:

$csvContent[0] =~ s/\r$//;

etc.

Replies are listed 'Best First'.
Re^2: Strings overwrite themselves in print command
by tdsny71 (Initiate) on Jun 28, 2016 at 06:28 UTC

    Thanks very much. It gets me closer, but only works on the lines with a group name. Stripping the same character from the line with the member info

    Result (with your suggestion):
    applegroup,
    applegroup,
    applegroup,
    applegroup,
    orangegroup,
    orangegroup,
    orangegroup,

    Thanks