10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
Hi ,
I have a file which is like below. The file record is separated by | as delimiter. I want to remove the first and last | in the file and also I want to remove the spaces in the columns.
Original File
|3464114 |10 | REPORT|CA| 1|0|4825400|0|213167| 939396524|
Expected:... (3 Replies)
Discussion started by: arunkumar_mca
3 Replies
2. Shell Programming and Scripting
Hello,
I have an ffmpeg bash script which is working nice and
I need to do the same for other sources.
To create new scripts and to deal with multiple bash files sounds not logical. It is a bit hard to manage for me..
I wondered if it was possible to make my input file as variable.
Then I... (1 Reply)
Discussion started by: baris35
1 Replies
3. Shell Programming and Scripting
How do I pipe the output of something to a filename that includes the date, in a specific date format?
Here's the goal. Output a script to a file periodically during the day:
./script.sh >>logname_yyyy-mm-dd.logAnd when the next day comes, it starts logging to a new filename because the date... (2 Replies)
Discussion started by: nbsparks
2 Replies
4. Shell Programming and Scripting
I have file like below
abc 12 34 45 code
abcdef 451 1 4 code
ghtyggg 4 56 3 code
I need to change this to
abc|12|34|45|code|
abcdef|451|1|4|code|
ghtyggg|4|56|3|code|
I tried replace space with | in sed ... but in the middle some row has... (7 Replies)
Discussion started by: greenworld123
7 Replies
5. Shell Programming and Scripting
HI
i have written a script to ask input from the user.
this script should promote the user for y/n input. if user enters anyother input then y/n
the script promotes him again. this below code is working fine for all the cases.
except for space and enter " if i give space and enter it is... (2 Replies)
Discussion started by: BHASKARREDDY006
2 Replies
6. Shell Programming and Scripting
Hi all,
I would like to use properly an input pipe, like this :
cat myFile.txt | myCommand.shI always find this solution :
while read line; do ...; donebut I have a great lost of performance !
On a big file, with a simple grep, I can spend 2400 times more time ! oO
(from 0,023sec to 1m)... (4 Replies)
Discussion started by: LeNouveau
4 Replies
7. UNIX for Dummies Questions & Answers
uname -a
SunOS mypc 5.10 Generic_141414-07 sun4v sparc SUNW,SPARC-Enterprise-T2000
uname -a
SunOS mypc 5.10 Generic_144488-07 sun4v sparc SUNW,SPARC-Enterprise-T5220
find . -name "*.cer" -exec keytool -v -list -printcert -file {} \; | grep -i "Aug 03"
Valid from: Mon Jan 29 00:00:00 GMT... (16 Replies)
Discussion started by: shifahim
16 Replies
8. Shell Programming and Scripting
Hi,
I have a directory with around 100k files and files with varying sizes(10GB files to as low as 5KB). All the files are having pipe dilimited records.
I need to append 7 pipes to the end of each record, in each file whose name contains _X3_ and need to append 10 pipes to the end of each... (3 Replies)
Discussion started by: nss280
3 Replies
9. AIX
Hi,
On AIX 5200-07-00 I have a find command as following to delete files from a certain location that are more than 7 days old. I am being told that I cannot use -exec option to delete files from these directories.
Having said that I am more curious to know how this can be done.
an sample... (3 Replies)
Discussion started by: jerardfjay
3 Replies
10. UNIX for Dummies Questions & Answers
Hello All,
I have a file with thousands of records:
eg:
|000222|123456987|||||||AARONSON| JOHN P|||PRIMARY |P
|000111|567894521|||||||ATHENS| WILLIAM k|||AAAA|L
Expected:
|000222|123456987|||||||AARONSON| JOHN |P|||PRIMARY |P
|000111|567894521|||||||ATHENS| WILLIAM |k|||AAAA|L
I... (6 Replies)
Discussion started by: OSD
6 Replies