Sponsored Content
Full Discussion: Parsing a variable
Top Forums UNIX for Dummies Questions & Answers Parsing a variable Post 302447676 by siba.s.nayak on Tuesday 24th of August 2010 03:15:15 AM
Old 08-24-2010
Why don't you use basename and dirname command?
Code:
basename /app/myapp/bin/my.sql
my.sql

Code:
dirname /app/myapp/bin/my.sql
/app/myapp/bin

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Parsing a variable string

Hi all, I have a problem surfacing and I hope you all could help. What I have to do is take a input file and fill out a fax template from that file. The biggest problem I found was I have to parse the string "//FAX(faxnumber=555-5555;style="style1"; and on and on. The string can be in any... (5 Replies)
Discussion started by: pageld
5 Replies

2. UNIX for Dummies Questions & Answers

Parsing a variable length record

I need to pick a field out of a variable record - the field is always found 4 fields after a certain text string, but it can be on any line of the record and in any position across the record on a line. I have had no luck through any of the Unix editors being able to cut a field that isn't always... (17 Replies)
Discussion started by: Barb
17 Replies

3. Shell Programming and Scripting

parsing a string into variable

I know solution to this but I was wondering if its easier than what i think I have to pass 20 parameters to a script, which of course is not working so I parsed $3 to be a pipe deliminated string for instance below a.ksh One Two Compa|Compb|Compc|compd|............. Now i have to read... (5 Replies)
Discussion started by: Anubhav
5 Replies

4. Shell Programming and Scripting

parsing a variable

Hi, I want to get an input from user and parse the input. The legal characters allowed in the input are alnum(a-zA-Z0-0), . , - Also the first and las characters must be alnum only. e.g if the input is abc.ghh-sok.com then the script should return correct, and if the input is like... (2 Replies)
Discussion started by: g_rohit7
2 Replies

5. Shell Programming and Scripting

Parsing a variable length file

Hi I am new to shell scripting. I need to parse a file which contains the header and detail records and split into n of file based on dept ID, for ex. INPUT FILE: DEPT ID: 1 EMPNAME: XYZ EMPAddress: XYZZZ DEPT ID: 2 EMPNAME: ABC EMPAddress: ABCD DEPT ID: 1 EMPNAME: PQR EMPAddress:... (6 Replies)
Discussion started by: singhald
6 Replies

6. Shell Programming and Scripting

Parsing file list in variable

Hello, somewhere in a shell script, i am storing the output of "ls" into a variable. My question is how can i parse this variable to get each filepath. I don't want to create a temporary file to write down all the filenames and then parse it.. is there a easy way out.. here is what... (3 Replies)
Discussion started by: prasbala
3 Replies

7. Shell Programming and Scripting

XML parsing with a variable

I have the following XML <Audit_Type>1</Audit_Type><Session_Id>34505863</Session_Id> <StatementId>1</StatementId><EntryId>1</EntryId> <Extended_Timestamp>2012-03-06T10:25:20.789459</Extended_Timestamp> <DB_User>KASINIY</DB_User> <OS_User>majohn1</OS_User><OS_Process>28636</OS_Process>... (3 Replies)
Discussion started by: BeefStu
3 Replies

8. Shell Programming and Scripting

Parsing Output of a Variable

i have a log file that contains something similar to this: one two three four five six seven eight nine ten eleven twelve thirteen fourteen one two three four five six seven eight nine ten eleven twelve thirteen fourteen one two three four five six seven eight nine ten eleven twelve... (3 Replies)
Discussion started by: SkySmart
3 Replies

9. Shell Programming and Scripting

Parsing a $VARIABLE within a script.

Hello all, I have a situation where I need to parse for certain items from a $VARIABLE within a sh script. The sh script is run when an alert comes in. The alert data payload has a Message field called "EVENTMSG" The script that is run takes the "EVENTMSG" and prints it out to the... (12 Replies)
Discussion started by: dlundwall
12 Replies

10. Shell Programming and Scripting

Parsing csv file and pass to a variable

Hi, Newbie here and I need some help to parse a csv file that contains fields separated by ",". What I need to achieve here is, read the 1 line file and extract 240 fields and pass to a variable and then read the next 240 fields and pass to a variable, over and over. If anyone can assist that... (4 Replies)
Discussion started by: tmslixx
4 Replies
GUPNP_SERVICE_PROXY_ADD_NOTIFY(3)					 1					 GUPNP_SERVICE_PROXY_ADD_NOTIFY(3)

gupnp_service_proxy_add_notify - Sets up callback for variable change notification

SYNOPSIS
bool gupnp_service_proxy_add_notify (resource $proxy, string $value, int $type, mixed $callback, [mixed $arg]) DESCRIPTION
Sets up callback to be called whenever a change notification for variable is recieved. PARAMETERS
o $proxy - A service proxy identifier. o $value - The variable to add notification for. o $type - The type of the variable. Type can be one of the following values: o GUPNP_TYPE_BOOLEAN - Type of the variable is boolean. o GUPNP_TYPE_INT - Type of the variable is integer. o GUPNP_TYPE_LONG - Type of the variable is long. o GUPNP_TYPE_DOUBLE - Type of the variable is double. o GUPNP_TYPE_FLOAT - Type of the variable is float. o GUPNP_TYPE_STRING - Type of the variable is string. o $callback - The callback to call when variable changes. Typically, callback function takes on three parameters. The $variable parameter being the first, $value parameter being the second, and the $arg is third. o $arg - User data for $callback. RETURN VALUES
Returns TRUE on success or FALSE on failure. SEE ALSO
gupnp_service_proxy_remove_notify(3). PHP Documentation Group GUPNP_SERVICE_PROXY_ADD_NOTIFY(3)
All times are GMT -4. The time now is 08:07 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy