Hi All,
How can i replace the n'th occurance in a file. ?
I have a property file like
EAR;_TrackingEAR;META-INF/application.xml;xml;context-root;1;valeur
EAR;_TrackingEAR;META-INF/application.xml;xml;context-root;2;valeur2... (2 Replies)
Input:
--------------------------
123asd 456sdasda 789a
-------------------------
output wanted:
---------------------
123asd
456sdasda
789a
----------------------
I want this by sed in simple way
please help (I know by: tr ' ' '\n' < inputfile )I want it by sed only (5 Replies)
how to replace the 3rd colum? Each line begins similarly, but they all ends variously.
XX YY 03 variable text here
XX YY 03 more variable text here
XX YY 03 even more variable text here really long setence
XX YY 03 variable numbers also appear 03 11. 123 456
XX YY 03 the occasional comma,... (4 Replies)
I want to replace every 2nd occurance of a string/character from a line.
ababacbsbddbsbbcbdbssb
i want to replace every s2nd b with @ like below
should be like
aba@acbs@ddbs@bc@dbss@ (3 Replies)
Hi Guys,
I have a file with content as below
aj.txt
"Iam
allfine" abcdef
abcd "all is
not well"
What I'm trying to say is my data has some new line characters in between quoted text. I must get ride of the newline character that comes in between the quoted text.
output must be:... (8 Replies)
Hi ,
I have a file like
I want to add a new line before "Realized" only when it comes after "Sheep".
There may be any line betwwen "Sheep" and "Realized" other than this two.
Say my new line is "a goat", so the desired result would be
Can any body help me in this?
thanks (10 Replies)
Input eg:
Ouput Expected.
The #rd line had the unexpted new line, which need to be replaced with space.
I was planing to go with checking the length of each line using awk and if the length is less than the defeined limit, (12 in above case) will replace the newline with space.
... (5 Replies)
Hello
I have had a requirement where I need to move data to a new line based on a text .So basically as soon as it encounters :61: it should move to a new line
Source Data :
:61:D100,74NCH1 :61:D797,50NCH2 :61:D89,38NCHK2 :61:D99,38NCHK12 :61:D79,38NCHK22 :61:D29,38NCHK5
Target Data... (11 Replies)
I have a file abc.txt which has records like
456 /home/fgg/abdc.txt
3567 /home/fdss/vfgb.txt
23 /home/asd/dfght.txt
I WANT TO REMOVE STRING UNTIL 3RD OCCURANCE OF FORWARD SLASH
Output should be like
abdc.txt
vfgb.txt
dfght.txt (5 Replies)
Discussion started by: himanshupant
5 Replies
LEARN ABOUT ULTRIX
acct
acct(5) File Formats Manual acct(5)Name
acct - execution accounting file
Syntax
#include <sys/acct.h>
Description
The system call makes entries in an accounting file for each process that terminates. The accounting file is a sequence of entries whose
layout, as defined by the include file, is:
typedef u_short comp_t
struct acct
{
char ac_comm[10]; /* Accounting command name */
comp_t ac_utime; /* Accounting user time */
comp_t ac_stime; /* Accounting system time */
comp_t ac_etime; /* Accounting elapsed time */
time_t ac_btime; /* Beginning time */
short ac_uid; /* Accounting user ID */
short ac_gid; /* Accounting group ID */
short ac_mem; /* average memory usage */
comp_t ac_io; /* number of disk IO blocks */
dev_t ac_tty; /* control typewriter */
char ac_flag; /* Accounting flag */
};
#define AFORK 0001 /* has executed fork, but no exec */
#define ASU 0002 /* used super-user privileges */
#define ACOMPAT 0004 /* used compatibility mode */
#define ACORE 0010 /* dumped core */
#define AXSIG 0020 /* killed by a signal */
#define AHZ 64 /* the accuracy of data is 1/AHZ */
#ifdef KERNEL
struct acct acctbuf;
struct gnode *acctp;
#endif
If the process does an the first 10 characters of the file name appear in ac_comm. The accounting flag contains bits indicating whether
was ever accomplished and whether the process ever had superuser privileges.
See Alsoacct(2), execve(2), sa(8)
RISC acct(5)