Hi,
I have a data like
Input:
12||34|56|78
Output:
XYZ|12||34|56|78
I tried like this , but it puts it on another line
awk -F "|" ' BEGIN {"XYZ"} {print $0} 'file
Any quick suggessitons in sed/awk ? am using HP-UX
Hi,
I have a data like
Input:
12||34|56|78
Output:
XYZ|12||34|56|78
I tried like this , but it puts it on another line
awk -F "|" ' BEGIN {"XYZ"} {print $0} 'file
Any quick suggessitons in sed/awk ? am using HP-UX
Try:
sed 's/^/XYZ|/' file
Hello,
Could you please try the following command for same.
awk '{print "XYZ|"}'1 ORS="" filename
It will show output as follows.
XYZ|12||34|56|78
Thanks,
R. Singh
cool , both the solution works .... thanks a lot