I'm running against a file with 1008 records like this, all beginning '4760 Slave':
4760 Slave,7,3607 ,GL ,200605,11320024 , ,GBP ,X00033
,AI80190 ... (1 Reply)
ok so I have a list of names that end in either ot,om,oa.
So for example
DETOT
MANOA
DET0M
DET0A
MANOT
SEAOT
etc...
I want to be able to group this list by OT, OM, OA and have the output have some headers like this and be alphabatized and if possible be in colums instead of like... (10 Replies)
Hi,
How do I sort the output of find to provide a listing of files from oldest to newest?
For example, if I do a find /tmp -type f -print I want the output to be sorted in the order of the oldest to the newest file.
Thanks in advance. (2 Replies)
Hi
I have a file that is a fdupes output. I'd like to sort the duplicated file by size. The format file is the following:
5996544 bytes each:
/path1/to/file1.jpg
/path2/to/file1.jpg
/pathx/to/file1.jpg
... random number of lines
/path999/to/file1.jpg
591910 bytes each:... (2 Replies)
Hi all! I have a comma delimited file and I'm sorting it based on fields 6, 8 and 10. The following does the job:
sort -t, -nk6,10 unsorted.txt -o sorted.txt
What I need to do now is to write every row containing same values on fields 6, 8 and 10 to a different file.
Any ideas on how to do... (2 Replies)
Now I van sort in hour-minute-second. I need in seconds
ps -eo pid,etime,args --sort=start_time | grep bash
Sample Output
15064 03:23 -bash
I need in 03:23 in seconds (1 Reply)
Hi All,
I have one requirement, where I need to have output of ls -l command sorted on 1) first on filename 2) last modified time ( descending ) - latest change first.
I am not able to figure out how to do it..
Also I dont have a way to change Date display for ls -ltr command..
I am... (5 Replies)
with a command i get a long list (example) and the entrys are intended.
DName=AAAAA
DName=AAAAA
lba=838,860,800
label=ftw_1
DName=BBBBB
DName=BBBBB
lba=838,860,800
label=ftw_2
DName=CCCCC
... (3 Replies)
Hi,
This is one of the thing that am looking for when I post the question on the ps wrapper. It has since been closed as it has taken me too long to post an example.
I have replaced some of the original content of the ps output.
uname -a = SunOS <hostname> 5.11 11.3 sun4v sparc sun4v
... (1 Reply)
Discussion started by: newbie_01
1 Replies
LEARN ABOUT REDHAT
date::parse
Date::Parse(3) User Contributed Perl Documentation Date::Parse(3)NAME
Date::Parse - Parse date strings into time values
SYNOPSIS
use Date::Parse;
$time = str2time($date);
($ss,$mm,$hh,$day,$month,$year,$zone) = strptime($date);
DESCRIPTION
"Date::Parse" provides two routines for parsing date strings into time values.
str2time(DATE [, ZONE])
"str2time" parses "DATE" and returns a unix time value, or undef upon failure. "ZONE", if given, specifies the timezone to assume when
parsing if the date string does not specify a timezome.
strptime(DATE [, ZONE])
"strptime" takes the same arguments as str2time but returns an array of values "($ss,$mm,$hh,$day,$month,$year,$zone)". Elements are
only defined if they could be extracted from the date string. The $zone element is the timezone offset in seconds from GMT. An empty
array is returned upon failure.
MULTI-LANGUAGE SUPPORT
Date::Parse is capable of parsing dates in several languages, these are English, French, German and Italian. Changing the language is done
via a static method call, for example
Date::Parse->language('German');
will cause Date::Parse to attempt to parse any subsequent dates in German.
This is only a first pass, I am considering changing this to be
$lang = Date::Language->new('German');
$lang->str2time("25 Jun 1996 21:09:55 +0100");
I am open to suggestions on this.
EXAMPLE DATES
Below is a sample list of dates that are known to be parsable with Date::Parse
1995:01:24T09:08:17.1823213 ISO-8601
1995-01-24T09:08:17.1823213
Wed, 16 Jun 94 07:29:35 CST Comma and day name are optional
Thu, 13 Oct 94 10:13:13 -0700
Wed, 9 Nov 1994 09:50:32 -0500 (EST) Text in ()'s will be ignored.
21 dec 17:05 Will be parsed in the current time zone
21-dec 17:05
21/dec 17:05
21/dec/93 17:05
1999 10:02:18 "GMT"
16 Nov 94 22:28:20 PST
BUGS
When both the month and the date are specified in the date as numbers they are always parsed assuming that the month number comes before
the date. This is the usual format used in American dates.
The reason why it is like this and not dynamic is that it must be deterministic. Several people have suggested using the current locale,
but this will not work as the date being parsed may not be in the format of the current locale.
My plans to address this, which will be in a future release, is to allow the programmer to state what order they want these values parsed
in.
AUTHOR
Graham Barr <gbarr@pobox.com>
COPYRIGHT
Copyright (c) 1995 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.8.0 2002-06-06 Date::Parse(3)