06-12-2008
If you have Perl available, you can try this:
echo $tname | perl -pe 's/.*(\d\d\d\d\d\d\s?-?\s?\d?).*/$1/'
Hope this helps.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
> tnsping $TWO_TASK | grep HOST
Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 10.12.10.212)(PORT = 1540)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = OMTST15)))
I want to extract like this
HOST = 10.12.10.212
PORT = 1540
SERVICE_NAME = OMTST15
I... (4 Replies)
Discussion started by: dashok.83
4 Replies
2. Shell Programming and Scripting
I have a shell script that uses wget to grab a bunch of html from a url.
URL_DATA=`wget -qO - "$URL1"`
I now have a string $URL_DATA that I need to pull a substring out of..say I had the following in my string
<p><a href="/scooby/929011567.html">Dog pictures check them out! -</a><font... (3 Replies)
Discussion started by: shellpower
3 Replies
3. UNIX for Dummies Questions & Answers
This is the line that I am using:
sed 's/^*\({3}*$\)/\1 /' <test.txt >results.txt
and suppose that test.txt contains the following lines:
http://www.example.com/200904/AUS.txt
http://www.example.com/200903/_RUS.txt
http://www.example.com/200902/.FRA.txt
What I expected to see in results.txt... (6 Replies)
Discussion started by: figaro
6 Replies
4. Solaris
i have srtring i.e. "NAME,CLASS,AGE" (length of string is not constant) and from this string i've extract each word delimited by "," (comma).
INPUT: "NAME,CLASS,AGE"
OUTPUT: NAME
CLASS
AGE
how can i do that?
i have tried some string manipulation function like... (5 Replies)
Discussion started by: jadoo_c2
5 Replies
5. Shell Programming and Scripting
Hi,
I have an input string say for example:
ABC,DEF,IJK,LMN,...,XYZ
The above string is comma delimited. Now I have to extract the last part after the comma i.e. XYZ.
:b: (3 Replies)
Discussion started by: bghosh
3 Replies
6. Shell Programming and Scripting
Hi All,
I have a log file in which name and version of applications are coming in the following format
name
It may look like following, based on the name of the application and version:
XYZ OR xyz OR XyZ OR xyz
I want to separate out the name and version and store them into variables.... (4 Replies)
Discussion started by: bhaskar_m
4 Replies
7. Shell Programming and Scripting
Hi
Input:
aa-bb-cc-dd.ee.ff.gg
Output:
dd
I want to get the word after the last '-' until the first dot
I have tried with regex lookbehind and lookahead like this:
(?<=-).*(?=\.)
but his returns too much
bb-cc-dd.ee.ff (7 Replies)
Discussion started by: chitech
7 Replies
8. Shell Programming and Scripting
Hello,
A question please.
A have a file that contains a string. Ex:
AAAABBCCCCCDDEEEEEEEEEEFF
I'd want to recover 2 substrings, 'BB' and 'FF' and then leave them in a new file.
Could anoyone help me please?
Thanks in advance (3 Replies)
Discussion started by: nolo41
3 Replies
9. Shell Programming and Scripting
Hello,
A question please.
A have a file that contains a string. Ex:
AAAABBCCCCCDDEEEEEEEEEEFF
I'd want to recover 2 substrings, 'BB' and 'FF' and then leave them in a new file.
From position 5, 2 caracters (ex:"BB") and from position 25, 2 caracters (ex:"FF") in a file.
Could anoyone help me... (3 Replies)
Discussion started by: nolo41
3 Replies
10. Shell Programming and Scripting
Hi all,
Please, i'd like to extract string just before '.fr'.
Here is some lines of my file:
g-82.text.text1.fr.worker1
g-xx.yyyyyy.zzzz.fr.worker2
i'd like to extract this text:
g-82.text.text1
g-xx.yyyyyy.zzzz
Please, which command i have to use in my script shell ?
... (16 Replies)
Discussion started by: chercheur111
16 Replies
LEARN ABOUT DEBIAN
sogllightidelement
SoGLLightIdElement(3) Coin SoGLLightIdElement(3)
NAME
SoGLLightIdElement -
The SoGLLightIdElement class is yet to be documented.
FIXME: write doc.
SYNOPSIS
#include <Inventor/elements/SoGLLightIdElement.h>
Inherits SoInt32Element.
Public Member Functions
virtual void init (SoState *state)
FIXME: write doc.
virtual void push (SoState *state)
FIXME: write doc.
virtual void pop (SoState *state, const SoElement *prevTopElement)
FIXME: write doc.
Static Public Member Functions
static SoType getClassTypeId (void)
static int getClassStackIndex (void)
static void * createInstance (void)
static void initClass (void)
static int32_t increment (SoState *const state, SoNode *const node)
FIXME: write doc.
static int32_t increment (SoState *const state)
FIXME: write doc.
static int32_t get (SoState *const state)
FIXME: write doc.
static int32_t getDefault ()
FIXME: write doc.
static int32_t getMaxGLSources ()
FIXME: write doc.
Protected Member Functions
virtual ~SoGLLightIdElement ()
Additional Inherited Members
Detailed Description
The SoGLLightIdElement class is yet to be documented.
FIXME: write doc.
Constructor & Destructor Documentation
SoGLLightIdElement::~SoGLLightIdElement (void) [protected], [virtual]
The destructor.
Member Function Documentation
SoType SoGLLightIdElement::getClassTypeId (void) [static]
This static method returns the class type.
Reimplemented from SoInt32Element.
int SoGLLightIdElement::getClassStackIndex (void) [static]
This static method returns the state stack index for the class.
Reimplemented from SoInt32Element.
void * SoGLLightIdElement::createInstance (void) [static]
This API member is considered internal to the library, as it is not likely to be of interest to the application programmer.
void SoGLLightIdElement::initClass (void) [static]
This static method initializes static data for the SoGLLightIdElement class.
Reimplemented from SoInt32Element.
Author
Generated automatically by Doxygen for Coin from the source code.
Version 3.1.3 Wed May 23 2012 SoGLLightIdElement(3)