05-18-2005
Please read our
rules which state:
(4) Do not 'bump up' questions if they are not answered promptly. No duplicate or cross-posting and do not report a post where your goal is to get an answer more quickly.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi,
I am currently confused.
Suppose I have a file something like the one below.
4299|raj Telecommunications|12|||||
4302|anjali International Ltd.|86|ritchie||dong|(000)2890 9993 |(222)4881 3689
4305|フィデュシアリ・ト-スト・インター...ショ...ル投資顧問株式会社 |112||||01-9211-1931 |08-3677-1985
Now... (2 Replies)
Discussion started by: rooh
2 Replies
2. Shell Programming and Scripting
Hi,
how to i remove leading and trailing spaces from a line? the spaces can be behind or in front of any field or line
example of a line in the input data:
Amy Reds , 100 , /bin/sh
how to i get it to be: Amy Read,100,/bin/sh
i saw something on this on the Man pages for AWK... (7 Replies)
Discussion started by: sleepster
7 Replies
3. Shell Programming and Scripting
I am trying to strip all leading and trailing spaces of a shell variable using either awk or sed or any other utility, however unscuccessful and need your help.
echo $SH_VAR | command_line Syntax.
The SH_VAR contains embedded spaces which needs to be preserved. I need only for the leading and... (6 Replies)
Discussion started by: jerardfjay
6 Replies
4. Shell Programming and Scripting
Hi All
I have a file of the following format (delimited by |)
this is field 1 | field 2 (lots of blank spaces) | field 3 (lots of blank space) |
field 1 | more text (lots of blank spaces) | dhjdsk |
Is there a way I can remove... (6 Replies)
Discussion started by: djkane
6 Replies
5. UNIX for Dummies Questions & Answers
hey guys, i have an XML like this:
<documents>
<document>
<Object ID>100114699999</Object ID>
<Object Create Date Time>2008-04-07T00:00:00</Object Create Date Time>
</document>
<documents>
I need all my tags within the XML to not include any spaces. i.e. everything between <t a g> in... (8 Replies)
Discussion started by: sharoff
8 Replies
6. Shell Programming and Scripting
Dear All,
can you please advice how do i remove trailing and leading spaces from a pipe-delimited file using "tr" command
the below cmd, i tried removed all spaces
tr -d ' '<s1.txt>s2.txt1
Many thx
Suresh (5 Replies)
Discussion started by: sureshg_sampat
5 Replies
7. Shell Programming and Scripting
Hi All,
I have a file with the following contents with multiple lines
172445957| 000005911|8| 400 Peninsula Ave.#1551 | And,K |935172445957|000005911
607573888 |000098536 | 2|Ane, B |J |Ane |1868 |19861206|20090106|20071001
I want to trim the "leading and trailing spaces only" from... (2 Replies)
Discussion started by: kumar04
2 Replies
8. Shell Programming and Scripting
Hi All,
I am trying to replace the value of a xml tag with a new one. But, the existing value in the xml contain leading spaces and I tried to remove that with different sed commands but all in vain.
For replacing the value I wrote the command in BOLD letters below:
bash-3.00$... (3 Replies)
Discussion started by: khedu
3 Replies
9. Shell Programming and Scripting
Hi,
I am trying to remove leading and trailing spaces from a file using awk but somehow I have not been able to do it.
Here is the data that I want to trim.
07/12/2017 15:55:00 |entinfdev |AD ping Time ms | .474| 1.41| .581|green |flat... (9 Replies)
Discussion started by: svajhala
9 Replies
10. Shell Programming and Scripting
Hi
I have variable named tablename. The value to tablename variable has leading and trailing white spaces. How to remove the leading and training white spaces and write the value of the tablename without space to a file using shell script. ( for e.g. tablename= yyy )
INPUT
... (10 Replies)
Discussion started by: pottic
10 Replies
LEARN ABOUT HPUX
pthread_setcancelstate
pthread_setcancelstate(3T) pthread_setcancelstate(3T)
NAME
pthread_setcancelstate(), pthread_setcanceltype() - set and retrieve current thread's cancelability state or type.
SYNOPSIS
PARAMETERS
state Value to which the cancelability state of the calling thread is to be set.
oldstate Pointer to the location where the old cancelability state of the calling thread will be returned.
type Value to which the cancelability type of the calling thread is to be set.
oldtype Pointer to the location where the old cancelability type of the calling thread will be returned.
DESCRIPTION
atomically sets the calling thread's cancelability state to the value in state and returns the previous cancelability state in oldstate.
The legal values for state are:
Disable cancelability for the calling thread.
Cancellation requests against the calling thread are held pending.
Enable cancelability for the calling thread.
Cancellation requests against the calling thread may be acted upon. When a pending cancellation request will be acted upon
depends on the thread's cancelability type.
By default, a thread's cancelability state is set to when it is created.
atomically sets the calling thread's cancelability type to the value in type and returns the previous cancelability type in oldtype. The
legal values for type are:
New or pending cancellation requests against the calling thread may be acted
upon at any time (if cancellation is enabled for the calling thread).
Cancellation requests for the calling thread are held pending until a
cancellation point is reached.
A thread's cancelability type is set to when it is created.
If a thread's cancelability state is disabled, the setting of the thread's cancelability type has no immediate effect. All cancellation
requests are held pending. However, once cancelability is enabled again, the new type will be in effect.
RETURN VALUE
Upon successful completion, and return zero. Otherwise, an error number is returned to indicate the error (the variable is not set).
ERRORS
For each of the following conditions, if the condition is detected, the and functions return the corresponding error number:
[EINVAL] state contains an invalid value.
[EINVAL] type contains an invalid value.
NOTES
Only functions that are async-cancel safe should be called from a thread that is asynchronously cancelable.
AUTHOR
and were derived from the IEEE POSIX P1003.1c standard.
SEE ALSO
pthread_exit(3T), pthread_join(3T), pthread_cancel(3T), pthread_cond_wait(3T), pthread_cond_timedwait(3T).
STANDARDS CONFORMANCE
Pthread Library pthread_setcancelstate(3T)