Sponsored Content
Top Forums Shell Programming and Scripting parse of lines with different delimiters Post 302195877 by nathasha on Friday 16th of May 2008 05:46:42 AM
Old 05-16-2008
Hi Penchal,

I want to parse the highlighted values.

2007:10:01:00:00:49:GMT: subject=BMRA.BM.T_ABTH7.FPN, message={SD=2007:10:01:00:00:00:GMT,SP=5,NP=2,TS=2007:10:01:01:00:00:GMT,VP=0.0,TS=2007:10:01:01:30: 00:GMT,VP=0.0}

First output column (2007-10-01): SD=2007:10:01:00:00:00

Second column (T_ABTH7): subject=BMRA.BM.T_ABTH7.FPN

Third Column (2007-10-0100:00:00): TS=2007:10:01:01:00:00

Fourth Column (5): SP=5

Fifth Column(0.0) : VP=0.0

Output for a single line :
2007-10-01,T_ABTH7,2007-10-0100:00:00,5,0.0

Please let me know if this clear.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Insert lines between delimiters

I'm working with a file like: somestuff somemorestuff ... someadditionalstuff STARTTAG ENDTAG someotherstuff somecoolstuff ... somefinalstuffI've got some text (either in a file or piped) to put between STARTTAG and ENDTAG. I was thinking something like grepping for the line number of... (2 Replies)
Discussion started by: BMDan
2 Replies

2. Shell Programming and Scripting

Parse and count lines

I have a data file in the following format (refer to input file) with multiple lines containing some information. I need an output file to loop thorough the input file with summarized information as seen below (refer to output file) ‘Date Time' and ‘Beta Id' input file values should be concatenated... (7 Replies)
Discussion started by: shekharaj
7 Replies

3. Shell Programming and Scripting

commenting out lines between two delimiters

Hi All, I am struggling to get my head around the following issue. I am having to comment out lines between two delimiters by placing an asterix in position 7 but retain all lines in the file and in the same order. so for example a file containing: ... ... DELIM1 ... ... DELIM2... (2 Replies)
Discussion started by: Bruble
2 Replies

4. Shell Programming and Scripting

Parse out specific lines

Hello, For the life of me, I can't figure out how to extract only certain lines of a file. For example, the file contains: project.max-sem-ids privileged 1.02K - deny - system 16.8M max deny ... (2 Replies)
Discussion started by: PointyWombat
2 Replies

5. UNIX for Dummies Questions & Answers

How to parse 2 particular lines from Command output

Hi All, I need help on the following req. I am getting output of a command as follows: 16377612 total memory 3802460 used memory 2827076 active memory 681948 inactive memory 12575152 free memory 477452 buffer memory I want to compute used... (1 Reply)
Discussion started by: mailsara
1 Replies

6. Shell Programming and Scripting

How to parse a numeric string without any delimiters?

Hi , I have a number say 12345001 which needs to be parsed. Its a number that has no delimiters.I have to read the last three digits and then the rest of digits irrespective of the total length of the number. The digits then have to be swapped and changed to a fixed length. The fillers to be... (10 Replies)
Discussion started by: Sheel
10 Replies

7. Shell Programming and Scripting

parse lines

I have file which is having 500 lines. I want to get the first 100 lines then sleep, then again next 100 lines sleep so now till the end of the file. Can someone tell me in perl and bash. also i want to do it in threads. Thanks.. (6 Replies)
Discussion started by: Anjan1
6 Replies

8. Shell Programming and Scripting

Concatinating the lines based on number of delimiters

Hi, I have a problem to concatenate the lines based on number of delimiters (if the delimiter count is 9 then concatenate all the fields & remove the new line char bw delimiters and then write the following data into second line) in a file. my input file content is Title| ID| Owner|... (4 Replies)
Discussion started by: bi.infa
4 Replies

9. Shell Programming and Scripting

awk: Print fields between two delimiters on separate lines and send to variables

I have email headers that look like the following. In the end I would like to accomplish sending each email address to its own variable, such as: user1@domain.com='user1@domain.com' user2@domain.com='user2@domain.com' user3@domain.com='user3@domain.com' etc... I know the sed to get rid of... (11 Replies)
Discussion started by: tay9000
11 Replies

10. Shell Programming and Scripting

Grep lines only with 3 delimiters

Hi All, my file has following Data 04:38:34 02:03 24:40 02:09:58 09:13 03:04:11 02:09:58 35:00 I want to display only lines with 3 fields. ie.. 04:38:34 02:09:58 03:04:11 (6 Replies)
Discussion started by: Arunselvan
6 Replies
Alzabo::PostgreSQL(3pm) 				User Contributed Perl Documentation				   Alzabo::PostgreSQL(3pm)

NAME
Alzabo::PostgreSQL - Alzabo and PostgreSQL DESCRIPTION
This documentation is about what special support Alzabo has for PostgreSQL, as well as what is lacking. Postgres support is based on the 7.3.x version of Postgres. Alzabo should work with the 7.1 and 7.2 series, and may even work with the 7.0 series. Mixed-case Table or Column Names By default, Postgres treats table and column names case-insensitively. Because of this, Alzabo always quotes these names when generating DDL SQL. If you are using tables or columns that contain upper-case characters, you should always call "$schema->set_quote_identifiers(1)" as soon as you load your schema object. Otherwise, any method which generates DML SQL will fail. Reverse Engineering o Alzabo cannot determine from the existence of a sequence that the sequence is meant to be used for a particular column unless the sequence was created as a result of making a column's type SERIAL. This is because there is no link between the two in the Postgres' data dictionary tables and will probably never change. Transactions o Transactions are fully supported with Postgres. Outer joins o Left and right outer joins are supported. o Full outer joins are not supported. Constraints Column constraints can be specified as column attributes. Table constraints can be specified as table attributes. Foreign key constraints are generated automatically based on the relationships defined by your schema. perl v5.8.8 2007-12-23 Alzabo::PostgreSQL(3pm)
All times are GMT -4. The time now is 10:58 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy