Posts Topics Forums Images
Search videos from message boards Videos Search messages from microblogs Microblogs Search messages from imdb.com Imdb Search messages from yuku.com Yuku Search messages from lefora.com (free forums) Lefora
My account: Login | Sign Up
Loading... 

Thread: print through AWK

Started 2 months ago by imipsita.rath
Hi friends I need one help from you . I want to print name='JACK' through . how can i make it . Code: awk '{print "name=jack"}' it ll print name=JACK
Site: The UNIX Forums - the Top UNIX & Linux Q&A on the Web  The UNIX Forums - the Top UNIX & Linux Q&A on the Web - site profile
Forum: Shell Programming and Scripting  Shell Programming and Scripting - forum profile
Total authors: 5 authors
Total thread posts: 7 posts
Thread activity: no new posts during last week
Domain info for: unix.com

Other posts in this thread:

zaxxon replied 2 months ago
awk lacks input so you'll have to put it for example into the BEGIN part: Code: awk 'BEGIN{print "name=jack"}'

imipsita.rath replied 2 months ago
it doesnt work . my requirement is output should be name='JACK'

danmero replied 2 months ago
Code: awk 'BEGIN{printf "name=%c%s%c",039,"JACK",039}' name='JACK'

ripat replied 2 months ago
Or: Code: awk 'BEGIN{print "name=\047JACK\047"}'

Amit.Sagpariya replied 2 months ago
or Code: awk 'BEGIN {print "name='"'"'JACK'"'"'"}'

ripat replied 2 months ago
Yet another (ugly) one: Code: awk 'BEGIN {print "name='\''JACK'\''"}'

 

Top contributing authors

Name
Posts
ripat
2
user's latest post:
print through AWK
Published (2009-10-14 08:16:00)
Yet another (ugly) one: Code: awk 'BEGIN {print "name='\''JACK'\''"}'
imipsita.rath
2
user's latest post:
print through AWK
Published (2009-10-14 08:16:00)
it doesnt work . my requirement is output should be name='JACK'
zaxxon
1
user's latest post:
print through AWK
Published (2009-10-13 06:06:00)
awk lacks input so you'll have to put it for example into the BEGIN part: Code: awk 'BEGIN{print "name=jack"}'
Amit.Sagpariya
1
user's latest post:
print through AWK
Published (2009-10-14 08:16:00)
or Code: awk 'BEGIN {print "name='"'"'JACK'"'"'"}'
danmero
1
user's latest post:
print through AWK
Published (2009-10-14 08:16:00)
Code: awk 'BEGIN{printf "name=%c%s%c",039,"JACK",039}' name='JACK'

Related threads on "The UNIX Forums - the Top UNIX & Linux Q&A on the Web":

Related threads on other sites:

Thread profile page for "print through AWK" on http://www.unix.com. This report page is a snippet summary view from a single thread "print through AWK", located on the Message Board at http://www.unix.com. This thread profile page shows the thread statistics for: Total Authors, Total Thread Posts, and Thread Activity