Have you tried using three " in a row. For example,
"""SiteVal""","""CustomerID"""

On Wed, 2003-06-11 at 12:17, Vidiot wrote:
> 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 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

Reply via email to