11-06-2011
Thanks heaps agama that has worked a treat. I can barley understand it but I'll work on it a bit more. Quick question, why does it need to be piped to the kshell?
Hi ygemici,
Thanks for your help. I tried this but it only works on files that have two words between the codes so running on files with more or less messes things up. Examples below:
VOD0001 Test M00000.pdf
VOD0001 Test three words M00003.pdf
VOD0001 Test two M00001.pdf
VOD0615 NEW Blades R77307.pdf
ends up with:
Test M00000.pdf
words M00003 three.pdf
M00001 Test two.pdf
R77307 NEW Blades.pdf
Cheers
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
I'm using Kshell scripts cronjobs to logrolling my daily log files and I stamped the log file at the end of the day by date stamp i.e.: %d_%m_%y-LogFile.
but the 22_01_2001-LogFile as example contains 21st Jan data and I want to stamp the log file with previous day.
so I'm trying to subtract... (3 Replies)
Discussion started by: tamer
3 Replies
2. Solaris
Help...please.
I have a log that contains
Warning Authentication Failed: User GHDT88998HS doesn't exit: The User GHDT88998HS could not be found Mar 22, 2008 5:22:22AM com.hometel.ttm.auth.userlogin.
about maybe a thousand entries failed user acct message
How can I grab just the username... (2 Replies)
Discussion started by: rivendell500
2 Replies
3. UNIX for Dummies Questions & Answers
I have a file like this:
Tue Apr 15 10:41:47 MDT 2008 FINAL RESULT; 6
Tue Apr 15 10:41:47 MDT 2008 FINAL RESULT; 2
Tue Apr 15 10:41:47 MDT 2008 FINAL RESULT; 5
With this command seira=`cut -f 2 -d ';' tes.txt` i take all the results (6,2,5 etc) and i store them in variable seira
When i do... (9 Replies)
Discussion started by: psalas
9 Replies
4. UNIX for Dummies Questions & Answers
Hi all,
I need help manipulating the file below.
Here is what I needed to do.
First, I have to replace INSUPD to DELETE.
Then I need to change the content of the file around by flipping the contents in the file from the bottom to the top (start from "CMD")
How should I attack this?
Here... (2 Replies)
Discussion started by: sirrtuan
2 Replies
5. Emergency UNIX and Linux Support
Hi. I haven't had to write bash scripts in a long time and have a simple task to do, but need some help:
Input:
chrY:22627291-22651542
chrY:23045932-23070172
chrY:23684890-23696359
chrY:25318610-25330083
chrY:25451096-25462570
chr10:1054847-1061799
chr10:1058606-1080131... (7 Replies)
Discussion started by: awknerd
7 Replies
6. Solaris
I need the command top to output as:
Memory: 2048M real, 1499M free, 53M swap in use, 5423M swap free
on just the memory line.
Instead, I have compiled the new version of top that displays as so:
Memory: 2048M phys mem, 1499M free mem, 5476 total swap, 5423M swap free
I read... (2 Replies)
Discussion started by: adelsin
2 Replies
7. Shell Programming and Scripting
Hi everybody,
I need an urgent help with a BASH script. I have file which contains (besides the other data) the lines with the following structure identified by with keyword PCList:
<PARAMETER NAME="PCList"
TYPE="LIST_STRUCTURE"
MODEL="{,}"
... (1 Reply)
Discussion started by: sameucho
1 Replies
8. Shell Programming and Scripting
Hi,
I need a shell/command to achieve this task.
I've a delimited unloaded file from oracle in a scrambled format as shown below with many blank lines in it, I'm just trying to tailor it in a format that would be compatible to view and load it to a IDS db.
Here is the problem
... (1 Reply)
Discussion started by: divak
1 Replies
9. UNIX for Dummies Questions & Answers
Hi Guys,
I'm really new to Unix and Linux and other scripting languages but recently I hv been really enthusiatic about learning more to help out on my work.
So I have a file with 3 columns. A sample of it looks like looks like this :
K2_537841 AAATCAGCCGCAACATTTGC ... (7 Replies)
Discussion started by: pawannoel
7 Replies
10. Shell Programming and Scripting
Not sure if the question posted in another forums can be moved by me.So posting the link here.
https://www.unix.com/unix-advanced-expert-users/221425-shell-script-manipulate-files.html#post302795379
Need your help here. (1 Reply)
Discussion started by: vedanta
1 Replies