Sponsored Content
Top Forums Shell Programming and Scripting Sorting multi-column values from a specific file Post 302455504 by canimsin on Tuesday 21st of September 2010 10:33:08 PM
Old 09-21-2010
this is perfect.. thank you very much, agama. you really helped me out... this is what I was looking.. well, one last thing, how can i store the value of DateTime attribute in a variable??
thanks "again"!!!
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Assistance with combining, sorting and saving multi files into one new file

Good morning. I have a piece of code that is currently taking multiple files and using the CAT.exe command to combine into one file that is then sorted in reverse order based on the 3rd field of the file, then displayed on screen. I am trying to change this so that the files are being combined into... (4 Replies)
Discussion started by: jaacmmason
4 Replies

2. UNIX for Dummies Questions & Answers

Switching the values in a specific column of a text file

Hi, I have a space de-limited text file. In the fifth column, I would like to switch "1"s with "2"s. How do I go about doing that? Thanks! Sample input: 0 311000259 0 0 1 1 0 311000397 0 0 1 2 0 311000491 0 0 2 1 0 311000516 0 0 2 1 0 311000541 0 0 1 1 0 311000558 0 0 2 1 0 311000566 0... (1 Reply)
Discussion started by: evelibertine
1 Replies

3. Shell Programming and Scripting

How to substract selective values in multi row, multi column file (using awk or sed?)

Hi, I have a problem where I need to make this input: nameRow1a,text1a,text2a,floatValue1a,FloatValue2a,...,floatValue140a nameRow1b,text1b,text2b,floatValue1b,FloatValue2b,...,floatValue140b look like this output: nameRow1a,text1b,text2a,(floatValue1a - floatValue1b),(floatValue2a -... (4 Replies)
Discussion started by: nricardo
4 Replies

4. UNIX for Dummies Questions & Answers

Sorting columns for specific values

Dear All, i have a column with values in excel table: ATGC22327-p66 ATGC15922-p239 ATGC12710-p21743567 ATGC08037-p186 ATGC07969-p173 ATGC07345-p48534 ATGC02767-p254234 ATGC02124-p2177451 ATGC02124-p1459 ATGC01930-p3005 I need to... (6 Replies)
Discussion started by: AAWT
6 Replies

5. Shell Programming and Scripting

Extract values from a specific column to the end

Hello friends, I have a text file with many columns (no. columns vary from row to row) separated by space. I need to collect all the values from 18th column to the end from each line and group them as pairs and then numbering like below.. 1. 18th-col-value 19th-col-value 2. 20th-col-value ... (5 Replies)
Discussion started by: prvnrk
5 Replies

6. Shell Programming and Scripting

Count specific column values

Hi all: quick question! I have the following data that resembles some thing like this: i am tired tired am i what is up hello people cool I want to count (or at least isolate) all of the unique elements in the 2nd column. I have tried this: cut -f 2 | uniq 'input' which does... (3 Replies)
Discussion started by: owwow14
3 Replies

7. Shell Programming and Scripting

Sum values of specific column in multiple files, considering ranges defined in another file

I have a file (let say file B) like this: File B: A1 3 5 A1 7 9 A2 2 5 A3 1 3 The first column defines a filename and the other two define a range in that specific file. In the same directory, I have also three more files (File A1, A2 and A3). Here is 10 sample lines... (3 Replies)
Discussion started by: Bastami
3 Replies

8. Shell Programming and Scripting

Sorting a specific column!

What im trying to do is sort the output by the number on the second column and than limit the result to only the first three lines. This is the code idlist="x23s52; f34233; 2343xs; 25x34; si342d" cntr=1 idcnt=$(print $nidlist |tr ';' '\n' |wc -l) numofgrps=0 while (($cntr <= $idcnt))... (3 Replies)
Discussion started by: ajetangay
3 Replies

9. Shell Programming and Scripting

Overwrite specific column in xml file with the specific column from adjacent line

I have an xml file dumped from rrd file, that I want to "patch" so the xml file doesn't contain any blank hole in the resulting graph of the rrd file. Here is the file. <!-- 2015-10-12 14:00:00 WIB / 1444633200 --> <row><v> 4.0419731265e+07 </v><v> 4.5045912770e+06... (2 Replies)
Discussion started by: rk4k
2 Replies

10. Programming

DB2 Query -Convert multi values from column to rows

Hi Team I am using DB2 artisan tool and struck to handle multi values present in columns that are comma(,) separated. I want to convert those column values in separate rows . For example : Column 1 Column2 Jan,Feb Hold,Sell,Buy Expected Result Column1 ... (3 Replies)
Discussion started by: Perlbaby
3 Replies
Rose::DateTime::Parser(3pm)				User Contributed Perl Documentation			       Rose::DateTime::Parser(3pm)

NAME
Rose::DateTime::Parser - DateTime parser object. SYNOPSIS
use Rose::DateTime::Parser; $parser = Rose::DateTime::Parser->new(time_zone => 'UTC'); $dt = $parser->parse_date('4/30/2001 8am') or warn $parser->error; DESCRIPTION
Rose::DateTime::Parser encapsulates a particular kind of call to Rose::DateTime::Util's parse_date and parse_european_date functions. The object maintains the desired time zone, which is then passed to each call. This class inherits from, and follows the conventions of, Rose::Object. See the Rose::Object documentation for more information. CONSTRUCTOR
new PARAMS Constructs a new Rose::DateTime::Parser object based on PARAMS, where PARAMS are name/value pairs. Any object method is a valid parameter name. OBJECT METHODS
error [ERROR] Get or set the error message string. european [BOOL] Get or set a boolean value that controls how the parse_date method will interpret "xx/xx/xxxx" dates: either month/day/year or year/month/day. If true, then the parse_date method will pass its arguments to Rose::DateTime::Util's parse_european_date function, which interprets such dates as "dd/mm/yyyy". If false, then the parse_date method will temporarily force non-European date parsing and then call Rose::DateTime::Util's parse_date function, which will interpret the date as "mm/dd/yyyy". This attribute defaults to the value returned by the Rose::DateTime::Util->european_dates class method called at the time the Rose::DateTime::Parser object is constructed. If the BOOL argument is undefined (instead of "false, but defined") then the attribute will return to its default value by calling the Rose::DateTime::Util->european_dates class method again. To unambiguously set the attribute to true or false, pass a defined value like 1 or 0. parse_date STRING Attempt to parse STRING by passing it to Rose::DateTime::Util's parse_date or parse_european_date function. The choice is controlled by the european attribute. If parsing is successful, the resulting DateTime object is returned. Otherwise, error is set and false is returned. parse_datetime STRING This method is an alias for parse_date() parse_european_date STRING Attempt to parse STRING by passing it to Rose::DateTime::Util's parse_european_date function (regardless of the value of the european attribute). If parsing is successful, the resulting DateTime object is returned. Otherwise, error is set and false is returned. time_zone [STRING] Get or set the time zone string passed to Rose::DateTime::Util's parse_date function. Defaults to the value returned by the Rose::DateTime::Util->time_zone class method. AUTHOR
John C. Siracusa (siracusa@gmail.com) LICENSE
Copyright (c) 2010 by John C. Siracusa. 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.12.3 2010-03-23 Rose::DateTime::Parser(3pm)
All times are GMT -4. The time now is 05:25 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy