>
> In all my years of using awk, this is the first time I've
> ever had to output
> a " character to a file. For example, I have the following:
>
> sprintf("%s,%s\n", SiteVal, CustomerID) >> "outputfile"
I suppose you could try
sprintf("%c%s%c,%c%s%c\n", '"', SiteVal, '"', '"', CustomerID, '"') >>
"outputfile"
A little hokey, but should work..........
>
>
> I need the line in the output file to look like:
>
> "SiteVal","CustomerID"
>
> I've tried "\"%s\",\"%s\"\n", but get a syntax error. Instead of \",
> I've tried \042 and still get a syntax error. I've tried
> adding another %s and
> supplying \" and \042 as the string, only to get errors.
>
> How does one get sprintf in awk to oputput a " character?
> The man page for
> sprintf doesn't say how to do it either.
>
> Thanks.
>
> MB
> --
> e-mail: [EMAIL PROTECTED] /~\
> The ASCII
> \ /
> Ribbon Campaign
> [So it's true, scythe matters. Willow 5/12/03] X Against
> Visit - URL: http://vidiot.com/ / \
> HTML Email
>
>
> --
> redhat-list mailing list
> unsubscribe mailto:[EMAIL PROTECTED]
> https://www.redhat.com/mailman/listinfo/redhat-list
>
--
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]
https://www.redhat.com/mailman/listinfo/redhat-list