How to receive message in 2 lines using mailx command

Hi,

I have a file with 2 records in two lines. While mailing these two records using mailx command, those two records coming in a single line. I have used the following command to send those records via mail.

cat filename | mailx -s "subject" mailaddress

I want the two records in seperate lines in the mail.

Please help me in this.

Thanks in advance.

Next time use CODE-tags when displaying code, data or logs to enhance readability and to keep formatting like indention etc., ty.

There should be nothing changed to the newline character. I just tried it out and both lines are separate. Maybe test it with another mail client - could be that it is displayed different. I am using Thunderbird.

It appeared as single line only. i tried with another mail client also.i am using target

Using HERE document might work.