[SunHELP] quoting and script generation

Markham, Richard RLMarkham at hafeleamericas.com
Thu Feb 12 12:48:55 CST 2004


If you try this you'll see that it doesn't work, the shell waits for more
input on command line or claims unmatched ' if redirecting to file.  I
beleive I will just play around ksh "print -n".

-----Original Message-----
From: Virginia Walters [mailto:vwalters at ceris.purdue.edu]
Sent: Thursday, February 12, 2004 1:10 PM
To: sunhelp at sunhelp.org
Subject: Re: [SunHELP] quoting and script generation


Try this:
     echo "allocate channel t1 type 'sbt_tape'
parms=\"ENV=(NB_ORA_CLIENT=mydb)\";"
or this:
     echo 'allocate channel t1 type \'sbt_tape\'
parms="ENV=(NB_ORA_CLIENT=mydb)";'

According to Markham, Richard:
>
>I'm trying to generate a text file which will contain alot
>of ' and " punctuation marks (an RMAN command script).
>
>example:
>
>#! /bin/ksh
>echo run{ > test.out
>echo 'allocate channel t1 type 'sbt_tape'
parms="ENV=(NB_ORA_CLIENT=mydb)";'
>>> test.out
>
>~~
>the resulting test.out is missing the ' marks around sbt_tape.
>
>TIA
>_______________________________________________
>SunHELP maillist  -  SunHELP at sunhelp.org
>http://www.sunhelp.org/mailman/listinfo/sunhelp
_______________________________________________
SunHELP maillist  -  SunHELP at sunhelp.org
http://www.sunhelp.org/mailman/listinfo/sunhelp



More information about the SunHELP mailing list