Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Help with awk using * (asterisk) as the delimiter Post 302759729 by PikK45 on Tuesday 22nd of January 2013 09:10:30 PM
Old 01-22-2013
Try this

Code:
LINE="14-OCT-2012 06:38:59 * (CONNECT_DATA=(SID=test)(GLOBAL_NAME=test.mydb.com.ch)(CID=(PROGRAM=Z:\Ora6i\BIN\ifrun60.EXE)(HOST=8000XXX05004RV)(USER=mickey))) * (ADDRESS=(PROTOCOL=tcp)(HOST=11.90.24.239)(PORT=1552)) * establish * test * 0"
echo $LINE

This will never provide the output that you expect. For this, I would replace all the "<space>*<space>" to another delimiter and then would try reading the lines from the file Smilie

Last edited by PikK45; 01-22-2013 at 10:20 PM..
 
Net::Time(3pm)						 Perl Programmers Reference Guide					    Net::Time(3pm)

NAME
Net::Time - time and daytime network client interface SYNOPSIS
use Net::Time qw(inet_time inet_daytime); print inet_time(); # use default host from Net::Config print inet_time('localhost'); print inet_time('localhost', 'tcp'); print inet_daytime(); # use default host from Net::Config print inet_daytime('localhost'); print inet_daytime('localhost', 'tcp'); DESCRIPTION
"Net::Time" provides subroutines that obtain the time on a remote machine. inet_time ( [HOST [, PROTOCOL [, TIMEOUT]]]) Obtain the time on "HOST", or some default host if "HOST" is not given or not defined, using the protocol as defined in RFC868. The optional argument "PROTOCOL" should define the protocol to use, either "tcp" or "udp". The result will be a time value in the same units as returned by time() or undef upon failure. inet_daytime ( [HOST [, PROTOCOL [, TIMEOUT]]]) Obtain the time on "HOST", or some default host if "HOST" is not given or not defined, using the protocol as defined in RFC867. The optional argument "PROTOCOL" should define the protocol to use, either "tcp" or "udp". The result will be an ASCII string or undef upon failure. AUTHOR
Graham Barr <gbarr@pobox.com> COPYRIGHT
Copyright (c) 1995-2004 Graham Barr. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. perl v5.18.2 2013-11-04 Net::Time(3pm)
All times are GMT -4. The time now is 09:12 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy