> From: Vidiot <[EMAIL PROTECTED]>
> Date: Wed, 11 Jun 2003 11:17:14 -0500 (CDT)
>
> 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"
>
How 'bout
outline = sprintf("\"%s\",\"%s\"\n", SiteVal, CustomerID)
>
> I've tried "\"%s\",\"%s\"\n", but get a syntax error. Instead of \",
Your syntax error is that sprintf "prints" to a string buffer, not a file.
Now, p'rhaps he wants fprintf, 'e does, Precious....
mark "will awk for $"
--
"The very powerful and the very stupid have one thing
in common. Instead of altering their views to fit the
facts, they alter the facts to fit their views...which
can be very uncomfortable if you happen to
be one of the facts that needs altering." - Doctor Who
--
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]
https://www.redhat.com/mailman/listinfo/redhat-list