egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

egrep -o implementation in tcl

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests
View previous topic :: View next topic  
Author Message
sander_vk
Voice


Joined: 06 Jul 2007
Posts: 4

PostPosted: Fri Jul 06, 2007 7:37 am    Post subject: egrep -o implementation in tcl Reply with quote

I'm writing a script to retrieve data from devices in a network. Now I want to put the data I retrieve into a SQL database for easy querying.

In order to do this I need to parse the retrieved data. Thereby I just want to retrieve the part that I am interested in.

I can do this using shell scripting and the following command:
egrep -o "[0-9]{1,2}:[0-9]{1,2}.[0-9]{1,2}:[0-9]{1,2}" < retrieved_data

But as my entire script will be running using a combination of TCL/EXPECT I am wondering how I can succeed using only that, thus not having to run seperate scripts from a shell script.

Anyone?
Back to top
View user's profile Send private message
rosc2112
Revered One


Joined: 19 Feb 2006
Posts: 1454
Location: Northeast Pennsylvania

PostPosted: Fri Jul 06, 2007 11:33 am    Post subject: Reply with quote

Use regexp
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber