sockread %data
set %output %output $chr(124) $gettok(%data,1,13)

will result in: "| line1 | line2 | line3" - to get rid of the first "| ", use e.g. $mid(%output,3-)