12-12-2007
Setting the delimiter
Hello all,
How can I set TAB as the delimiter inside a script file that will manipulate another file? For example, let's say I have a file with four fields separated by tabs and each field has four items. Can I set TAB as a delimiter inside a script file or can I only do that at the shell?
Thanks for any help!
Trellot
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
hey guys can you please help me out,
i'm having problem in cutting strings. I need a delimiter to cut string.
sample
a.txt
"ID", "1234" , "iam bighippo", "help!"
"ID", "1235" , "again0", "xxxxxxx1"
"ID", "1236" , "again1", "xxxxxxx2"
"ID", "1237" , "again2", "xxxxxxx3"
how do... (6 Replies)
Discussion started by: bighippo
6 Replies
2. UNIX for Dummies Questions & Answers
I am having the following file. I need to insert a delimiter in this file. I used sed but its not working.
AAABBB 9 JJJ
AAABBC 9 TTTTT
AAABBA 8 JJJ
AAABBC 7 TTTTT
AAABBC 6 TTTTT
Now i want the output file as:
AAA|BBB| |9| |JJJ|
AAA|BBC| |9| | |TTTTT| (3 Replies)
Discussion started by: sivakumar.rj
3 Replies
3. Shell Programming and Scripting
Hi,
I have a string like ABC.123.XYZ-A1-B2-P1-C4. I want to delimit the string based on "-" and then get result as only two strings. One with string till last hyphen and other with value after last hyphen... For this case, it would be something like first string as "ABC.123.XYZ-A1-B2-P1" and... (6 Replies)
Discussion started by: gupt_ash
6 Replies
4. Shell Programming and Scripting
Hi,
I am trying to load data from a file to oracle DB. The file am using has a ";" as a delimiter. While I load the file, I want to check whether the file is having the correct delimiter or not. if not, the file should not be processed. Is there any way that i could handle this scenario using... (3 Replies)
Discussion started by: smileyreddy
3 Replies
5. Shell Programming and Scripting
Hi all,
I have a number of strings like below:
//mnt/autocor/43°13'(33")W/
and i'm trying to get the numbers in this string, for example
431333
please help
thanks ahead (14 Replies)
Discussion started by: sunnydanniel
14 Replies
6. Shell Programming and Scripting
hi all,
i have a string with a number of "/"s as delimiter.
and i want everything BEFORE the last delimiter
i know to use basename to get everything after the last delimiter.
thx a lot! (2 Replies)
Discussion started by: sunnydanniel
2 Replies
7. Shell Programming and Scripting
Hi,
I have a No Delimiter variable length text file with following schema -
Column Name Data length
Firstname 5
Lastname 5
age 3
phoneno1 10
phoneno2 10
phoneno3 10
sample data - ... (16 Replies)
Discussion started by: Gaurav Martha
16 Replies
8. Solaris
Trying to figure out the best method of security for oracle user accounts. In Solaris 10 they are set as regular users but have nologin set forcing the dev's to login as themselves and then su to the oracle users.
In Solaris11 we have the option of making it a role because RBAC is enabled but... (1 Reply)
Discussion started by: os2mac
1 Replies
9. Shell Programming and Scripting
Hi,
Extremely new to Perl scripting, but need a quick fix without using TEXT::CSV
I need to read in a file, pass any delimiter as an argument, and convert it to bar delimited on the output. In addition, enclose fields within double quotes in case of any embedded delimiters.
Any help would... (2 Replies)
Discussion started by: JPB1977
2 Replies
10. UNIX for Dummies Questions & Answers
How to split 2:6..5 in to separate columns (7 Replies)
Discussion started by: Nadela
7 Replies
KPROF(3) Library Functions Manual KPROF(3)
NAME
kprof - kernel profiling
SYNOPSIS
bind -a #T /dev
/dev/kpctl
/dev/kpdata
DESCRIPTION
The kprof device provides simple profiling data for the operating system kernel. The data accumulates by recording the program counter of
the kernel at each `tick' of the system clock.
The file kpdata holds the accumulated counts as 4-byte integers in big-endian byte order. The size of the file depends on the size of ker-
nel text. The first count holds the total number of clock ticks during profiling; the second the number of ticks that occurred while the
kernel was running. The rest each hold the number of ticks the kernel program counter was within the corresponding 8-byte range of kernel
text, starting from the base of kernel text.
The file kpctl controls profiling. Writing the string start to kpctl begins profiling; stop terminates it. The message startclr restarts
profiling after zeroing the array of counts.
The program kprof (see prof(1)) formats the data for presentation.
EXAMPLE
The following rc(1) script runs a test program while profiling the kernel and reports the results.
bind -a '#T' /dev
echo start > /dev/kpctl
runtest
echo stop > /dev/kpctl
kprof /mips/9power /dev/kpdata
SOURCE
/sys/src/9/port/devkprof.c
SEE ALSO
prof(1)
KPROF(3)