![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Forum Rules | FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Double quotes or single quotes when using ssh? | password636 | Shell Programming and Scripting | 3 | 05-29-2008 05:52 PM |
| awk to print ' (single quotes) | orahi001 | UNIX for Dummies Questions & Answers | 2 | 03-11-2008 01:30 PM |
| problem with single quotes in a string and findbug | bob122480 | Shell Programming and Scripting | 9 | 01-19-2007 08:38 AM |
| im stuck! 'single quotes' | satnamx | UNIX for Dummies Questions & Answers | 4 | 03-29-2006 03:44 AM |
| Filename containing Single Quotes | phani | Shell Programming and Scripting | 6 | 03-30-2005 03:47 AM |
|
|
Submit Tools | LinkBack | Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Add single quotes in string
Hi All, I love this site, it helps newbie people like me and I appreciate everyone's help!
Here is my questions. I am trying to concatenate a single quote into a character/string from a text file for each line (lets say ABC should look like 'ABC'). I tried to use awk print command to do this, but it always gives me syntax error (i followed the awk document as it says). Is there a unix short cut command to do this ? thanks a lot! |
| Forum Sponsor | ||
|
|
|
#2
|
||||
|
||||
|
Code:
> val1="ABC" > echo $val1 ABC > val2="'$val1'" > echo $val2 'ABC' > val3="'""$val1""'" > echo $val3 'ABC' |
||||
| Google The UNIX and Linux Forums |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|