Combining header and data and send email without usage of temp file

Dear All-

My requirement is as below-
Header file
$ cat HEADER.txt

RequestId:
RequestDate:

Data file

$ cat DATAVAL.txt
1001|2009-03-01

I need to send the combined data below as email body [header+data] via mailx command
------------------

RequestId:1001
RequestDate:2009-03-01

I would like to achieve this using unix command alone and without usage of any temporary files to be created..

I tried something like below-

CMD1='cat CPG_HEADER.txt'
CMD2='tr -s "|" "\n" <CPG_VAL.txt'

e1=eval $CMD1
e2=eval $CMD2

Was trying to combine the above 2 evaluated command using paste command and then send via mailx, but this approach isn't working

Guys, please advice on this topic

Regards,
Suresh

awk -F\| 'NR==FNR{header[NR]=$0;next}{for (i=1;i<=NF;i++){print header $i}}' HEADER.txt DATAVAL.txt

This might work as you expect

nawk -F'|' 'FNR==NR {h[FNR]=$0;next}{for(i=1;i<=NF;i++) print h,$i}' HEADER.txt DATAVAL.txt | mailx myName@company.com

#! /bin/sh
unpipe=$(tr '|' ' ' < file2)
function foo {
while read line; do echo "${line}${1}"; shift; done < file1
}
foo $unpipe



# ./test
RequestId:1001
RequestDate:2009-03-01
#

Thank you guys..its working nw...any more suggestions are welcome...