Home > Archive > AWK > June 2004 > Single Quote removal
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Single Quote removal
|
|
|
| Hi
I am trying to run gsub("\'", "", $0) within a Unix Posix shell script
and it fails even before awk kicks in.
So, how do I remove singles quotes from a data line?
Thanks
afri
| |
| Ed Morton 2004-06-09, 3:55 pm |
|
Afri wrote:
> Hi
>
> I am trying to run gsub("'", "", $0) within a Unix Posix shell script
> and it fails even before awk kicks in.
> So, how do I remove singles quotes from a data line?
gawk -vsq=' '{gsub(sq, "");print}'
Regards,
Ed.
> Thanks
> afri
| |
|
| Ed Morton <morton@lsupcaemnt.com> wrote in message news:<ca77j9$h52@netnews.proxy.lucent.com>...[color=darkred]
> Afri wrote:
>
> gawk -vsq=' '{gsub(sq, "");print}'
>
> Regards,
>
> Ed.
>
PERFECT !!
Thank you very much.
|
|
|
|
|