Export Field Seperator

Brian K. White brian at aljex.com
Mon Aug 13 08:40:06 PDT 2012


On 8/13/2012 11:20 AM, Brian K. White wrote:
> This should work:
>
> export ascii alias = name r=\n o=| c=|
>
> But I haven't tried it.
>

Oh, I forgot, this should produce:

|aaa||bbb||ccc|

So you'll have to add an extra | to the beginning and end of the record 
yourself, maybe just by adding to those fields like
out(1) = "|" { 1
Kinda dirty but at least it's only the first and last field.

Two alternatives that avoid that but produce different output

export ascii out = filename r=\n f=| c=|

Should produce:
aaa||bbb||ccc||


export ascii out = filename r=\n f=| o=|

Should produce:
||aaa||bbb||ccc


Any of these three possible outputs should be fine in most cases.

But if your importer is really finnicky and not adjustable and you 
_must_ provide exactly
aaa||bbb||ccc
I see no way to do that without manually adding one | to the beginning 
or end of every field other than first & last.

(Or by post-processing the entire export file with a sed command in 
@done, which is ugly and needlessly prone to breakage and unportable.)

-- 
bkw


More information about the Filepro-list mailing list