LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   echo command (https://www.linuxquestions.org/questions/linux-newbie-8/echo-command-4175411095/)

oracledb0101 06-12-2012 03:30 PM

echo command
 
below is the result when I run the echo:

$echo 'Run (orastart.test);'
Run (orastart.test);

what can I do in order me to get the result as follow:

Run ('orastart.test');

###single tick in front and after orastart.test

Thanks

Tinkster 06-12-2012 03:56 PM

Code:

echo "Run ('orastart.test');"
Run ('orastart.test');


David the H. 06-13-2012 09:39 AM

1)
Please use ***[code][/code] tags*** around your code and data, to preserve formatting and to improve readability. Please do not use quote tags, colors, or other fancy formatting.

2)
Clearly point out the context of your question and the environment. What language is this in, for example? Shell scripting? Perl? What is the purpose of your query?

Please read How To Ask Questions The Smart Way, and provide enough detail in your posts so that readers don't have to guess.


Anyway, assuming the shell, Start with these three links for details on how it handles arguments and quoting.

http://mywiki.wooledge.org/Arguments
http://mywiki.wooledge.org/WordSplitting
http://mywiki.wooledge.org/Quotes

abdul_ahad 06-13-2012 05:49 PM

i think this is what you want

echo -n 'Run (orastart.test);'

Tinkster 06-13-2012 06:46 PM

Quote:

Originally Posted by abdul_ahad (Post 4702556)
i think this is what you want

echo -n 'Run (orastart.test);'

Can you elaborate on how that produces the output he desired?


All times are GMT -5. The time now is 08:39 PM.