![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Difference between using "echo" builtin and /bin/echo | ulidtko | Shell Programming and Scripting | 2 | 07-15-2009 12:12 PM |
| Using echo in AWK | jermaine4ever | Shell Programming and Scripting | 10 | 03-12-2009 01:24 PM |
| echo | tontal | Shell Programming and Scripting | 2 | 11-15-2006 12:20 PM |
| FTP--How to use echo?? | rahul26 | UNIX for Advanced & Expert Users | 1 | 06-14-2006 10:47 AM |
| How to set echo on | siegfried | Shell Programming and Scripting | 1 | 11-18-2005 01:56 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Using Echo
Hi All,
Need help in resoving the issue . Can anyone let me know how to get fix length using unix shellscript. For Ex: echo "NUMBER OF RECORDS "${NO_OF_ROWS}"\nFILE CREATION DATE&TIME "${PROD_DT}" output should be : NUMBER OF RECORDS 2546 CREATIN DATE&TIME 2009-12-01 Each record created in Unix should be of 80 byte length Kindly help me out on the same |
|
||||
|
Quote:
The echo command seems to automatically strip off leading and trailing whitespace, which thwarts you. But this should work: Code:
IFS= echo "Whatever ... " > outfile If you are counting lines in a file, use the wc command. Code:
wc -l file |
|
||||
|
Using Echo
Hey,
This is what i am looking for ... i have a shellscript whcih creates a report. Report has got 5 rows and each row should start from byte 1 and end at byte 80 . This should follow for the remainign 5 rows ..... hope this explains ..... |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|