Sponsored Content
Top Forums Shell Programming and Scripting Substring operation in kshell Post 302355939 by informsrini on Thursday 24th of September 2009 06:15:25 AM
Old 09-24-2009
Question Substring operation in kshell

Hi,
Please let me know how to perform the substring operation in kshell.
If i have line like below
238923893282389034893489458945904589045454903490

i would like to retrieve the position 7 to 19, how to do this in kshell?
 

10 More Discussions You Might Find Interesting

1. AIX

Kshell scripts and timing

Hello everyone, I have a script thats acting funky, what I would like to do is report to a file, how long its taking to get to certain area's, in seconds. For example. -- Start timer -- Run unix command 1 -- Run unix command 2 -- Stop timer -- Report Seconds -- etc etc Is there a way... (3 Replies)
Discussion started by: dbridle
3 Replies

2. UNIX for Dummies Questions & Answers

kshell variables and awk

Hi, Is it possible to initialise a shell variable and set it to a value from an awk command? i.e. #set myvalue = to the first 8 charachters of the line that begins with 0 myvalue = awk '/^0/ {substr($0,1,8)}' myvaluefile or even declare a variable, then reinitialise it as part of the... (1 Reply)
Discussion started by: kshelluser
1 Replies

3. Shell Programming and Scripting

running .sh script in kshell

hi i wrote a script in shell script(ChangeFiles.sh), now i need to run the script in korn shell. could anyone explain how to run the same script korn shell. thanks in advance Satya (2 Replies)
Discussion started by: Satyak
2 Replies

4. Shell Programming and Scripting

sed command for substring operation

Hi All, Input=abcDEF_1.6k1 I need to use ‘sed' command to get 1.6 value and store to some variable from the given input. Please help me in getting the command. Regards, Kalai (2 Replies)
Discussion started by: kalpeer
2 Replies

5. Shell Programming and Scripting

How to see a variable value outside a function in kshell

Hi, I wrote a small shell script which had function C_fun() and script name is same C_fun.ksh Here is the program inside the script #!bin/ksh -x C_fun() { typeset TEXT=${1} } echo Value of TEXT $TEXT When Im running the above script with Parameter "R" as the option .... (6 Replies)
Discussion started by: somu_june
6 Replies

6. Shell Programming and Scripting

KShell regular expresion

Hi, I would like to know if the parameter i am passing to a shell script is contain the following charachter : ASM. I belive that i should use regular expresion here. Can one help ? Bellow is the "if statment" i need to fix with the reg exp: if ; then #echo "IT IS AN RDBMS... (4 Replies)
Discussion started by: yoavbe
4 Replies

7. Linux

how to insert a title into a window in kshell

hi all, i am using a Ubuntu work station. i have following piece of code that works ok. But i cant figure out a way to insert a string call $Name into the title of the window i am opening. As you can see, i tried two different ways without a success. Can someone please help me out here? :( ... (3 Replies)
Discussion started by: usustarr
3 Replies

8. Shell Programming and Scripting

Column operation : cosne and sine operation

I have a txt file with several columns and i want to peform an operation on two columns and output it to a new txt file . file.txt 900.00000 1 1 1 500.00000 500.00000 100000.000 4 4 1.45257346E-07 899.10834 ... (4 Replies)
Discussion started by: shashi792
4 Replies

9. UNIX for Dummies Questions & Answers

Passing variable to Alias in Hp kshell

Hi all, I have a series of directories which i open regularly. I want create an alias so that i can pass the direcotry name to alias and then this commands makes Cd to the path i need. COuld you please help on how to create an alias ex of what i am trying but couldn't succeeded #alias... (1 Reply)
Discussion started by: firestar
1 Replies

10. Shell Programming and Scripting

Please help with Kshell Script!

I am an AIX noobie, and have a question around an AIX 5.2 script that I need to run. Security Audit requires us to have no World Writable files on our server, but every time we restart the Domino server on AIX it re-flags two files as World Writable. I have a little script that I created that... (5 Replies)
Discussion started by: Nebs
5 Replies
tt_message_address(library call)										  tt_message_address(library call)

NAME
tt_message_address -- retrieve the address attribute from a message SYNOPSIS
#include <Tt/tt_c.h> Tt_address tt_message_address( Tt_message m); DESCRIPTION
The tt_message_address function retrieves the address attribute from the specified message. The m argument is the opaque handle for the message involved in this operation. RETURN VALUE
Upon successful completion, the tt_message_address function returns a value that specifies which message attributes form the address of this message. The tt_message_address function returns one of the following Tt_address values: TT_HANDLER The message is addressed to a specific handler that can perform this operation with these arguments. TT_OBJECT The message is addressed to a specific object that can perform this operation with these arguments. TT_OTYPE The message is addressed to the type of object that can perform this operation with these arguments. TT_PROCEDURE The message is addressed to any process that can perform this operation with these arguments. The application can use tt_int_error(3) to extract one of the following Tt_status values from the returned integer: TT_OK The operation completed successfully. TT_ERR_NOMP The ttsession(1) process is not running and the ToolTalk service cannot restart it. TT_ERR_POINTER The pointer passed does not point to an object of the correct type for this operation. SEE ALSO
Tt/tt_c.h - Tttt_c(5), tt_int_error(3). tt_message_address(library call)
All times are GMT -4. The time now is 10:46 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy