07-10-2005
We have some
rules here. One of the them is:
(4) Do not 'bump up' questions if they are not answered promptly. No duplicate or cross-posting and do not report a post where your goal is to get an answer more quickly.
Don't break it again. Another issue is that you keep posting in the forum "Post Here to Contact Site Administrators and Moderators". That forum is not for technical questions, it's for issues with the site itself. Post your questions in an appropriate forum.
And by the way, putting conditions in like "Please Dont refer me to Datecalc as I want specific script to do so." is a good way to limit responses. When you're that selective you really need to hire an expert who will meet all of your demands.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hey all,
When you run the 'ls -la' command it'll show you the time and dates of all files/directories. Now what I am trying to do is create a script that will tell me what files haven't been used in over the past 1 month and what the time and date is that the files that haven't been accessed in... (2 Replies)
Discussion started by: merlin
2 Replies
2. Shell Programming and Scripting
Hi guys,
I know that this topic has been discuss numerous times, and I have search the net and this forum for it.
However, non able to address the problem I faced so far.
I am on Solaris Platform and unable to install additional packages like the GNU date and gawk to make use of their... (5 Replies)
Discussion started by: DrivesMeCrazy
5 Replies
3. Shell Programming and Scripting
Hello All,
I was having a look on threads on the Forum about time calculation but didn't find exactly this issue.
For instance, if we have these 2 dates, begin & end :
20100430235830
20100501000200
Is there anyway, awk, ksh, perl to calculate the difference in sec and get for... (6 Replies)
Discussion started by: rany1
6 Replies
4. Programming
Can we select the datetime from oracle database in “hhmmssnnnccyymmdd” format ?
please help to solve this..... (2 Replies)
Discussion started by: Sanal
2 Replies
5. Shell Programming and Scripting
Dear All,
Please help with a script which can accomplish the following:
Input table:
$1 $2 $3
Student1 1 50
Student2 56 75
Student3 77 100
Desired Output:
$1 $2 $3 $4
Student1 1 50
Student2 56 75 6
Student3 77 ... (4 Replies)
Discussion started by: saint2006
4 Replies
6. UNIX for Dummies Questions & Answers
Gurus,
From a file I need to remove duplicate rows based on the first column data but also we need to consider a date column where we need to keep the latest date (13th column).
Ex:
Input File:
Output File:
I know how to take out the duplicates but I couldn't figure out... (5 Replies)
Discussion started by: shash
5 Replies
7. Shell Programming and Scripting
Hi,
I'm trying to print and outrput of a timestamp from a script i did that calcs de time diference betwen 2 timestamps in the format HH:MM:SS and i properly formated it with printf inside awk, but i can't do it with separate statements.
This works fine, but can you explaim-me how to do it... (2 Replies)
Discussion started by: grafman
2 Replies
8. Shell Programming and Scripting
Hello all,
I have written sth like this:
#!/bin/bash
grep -e XXX -e YYYY myfile.log | grep -v ZZZ | awk '{print $1 " " $2 ";" $3 ";" $9 ";" $11}' > myfile.csv
sed -i '1iDate;Time;From;To' myfile.csv
=> it is clear that it converts log to csv and add a header.
Now I want to subtract row... (4 Replies)
Discussion started by: frhling
4 Replies
9. Shell Programming and Scripting
the given time is:
12:13:00
how do i subtract a 10 minutes from any given time?
date '12:13:00' '-10 min'
also tried this:
date +12:13:00 '-10 min' (2 Replies)
Discussion started by: SkySmart
2 Replies
10. UNIX for Dummies Questions & Answers
Hello All ,
Please support for below request
how to change format and subtract time and date and get average.
xxx 13-OCT-15 11.32.18.241000 AM 13-OCT-15 11.35.49.089080 AM
xxx 13-OCT-15 11.32.24.000000 AM 13-OCT-15 11.45.17.810904 AM
xxx 13-OCT-15 11.32.25.232000 AM ... (1 Reply)
Discussion started by: mirwasim
1 Replies
LEARN ABOUT DEBIAN
moosex::types::iso8601
MooseX::Types::ISO8601(3pm) User Contributed Perl Documentation MooseX::Types::ISO8601(3pm)
NAME
MooseX::Types::ISO8601 - ISO8601 date and duration string type constraints and coercions for Moose
SYNOPSIS
use MooseX::Types::ISO8601 qw/
ISO8601TimeDurationStr
/;
has duration => (
isa => ISO8601TimeDurationStr,
is => 'ro',
coerce => 1,
);
Class->new( duration => 60 ); # 60s => PT00H01M00S
Class->new( duration => DateTime::Duration->new(%args) )
DESCRIPTION
This module packages several TypeConstraints with coercions for working with ISO8601 date strings and the DateTime suite of objects.
DATE CONSTRAINTS
ISO8601DateStr
An ISO8601 date string. E.g. "2009-06-11"
ISO8601TimeStr
An ISO8601 time string. E.g. "12:06:34Z"
ISO8601DateTimeStr
An ISO8601 combined datetime string. E.g. "2009-06-11T12:06:34Z"
ISO8601DateTimeTZStr
An ISO8601 combined datetime string with a fully specified timezone. E.g. "2009-06-11T12:06:34+00:00"
COERCIONS
The date types will coerce from:
" Num "
The number is treated as a time in seconds since the unix epoch
" DateTime "
The duration represented as a DateTime object.
" Str "
Non-expanded date and time string representations.
e.g.:-
20120113 => 2012-01-13 170500Z => 17:05:00Z 20120113T170500Z => 2012-01-13T17:05:00Z
Representations of UTC time zone (only an offset of zero is supported)
e.g.:-
17:05:00+00:00 => 17:05:00Z 17:05:00+00 => 17:05:00Z 170500+0000 => 17:05:00Z
2012-01-13T17:05:00+00:00 => 2012-01-13T17:05:00Z 2012-01-13T17:05:00+00 => 2012-01-13T17:05:00Z 20120113T170500+0000 =>
2012-01-13T17:05:00Z
Also supports non-standards mixing of expanded and non-expanded representations
e.g.:-
2012-01-13T170500Z => 2012-01-13T17:05:00Z 20120113T17:05:00Z => 2012-01-13T17:05:00Z
DURATION CONSTRAINTS
ISO8601DateDurationStr
An ISO8601 date duration string. E.g. "P01Y01M01D"
ISO8601TimeDurationStr
An ISO8601 time duration string. E.g. "PT01H01M01S"
ISO8601DateTimeDurationStr
An ISO8601 comboined date and time duration string. E.g. "P01Y01M01DT01H01M01S"
COERCIONS
The duration types will coerce from:
" Num "
The number is treated as a time in seconds
" DateTime::Duration "
The duration represented as a DateTime::Duration object.
The duration types will coerce to:
" Duration "
A DateTime::Duration, i.e. the " Duration " constraint from MooseX::Types::DateTime.
SEE ALSO
o MooseX::Types::DateTime
o DateTime
o DateTime::Duration
o DateTime::Format::Duration
VERSION CONTROL
http://github.com/bobtfish/moosex-types-iso8601/tree/master
Patches are welcome.
SEE ALSO
o http://en.wikipedia.org/wiki/ISO_8601
o http://dotat.at/tmp/ISO_8601-2004_E.pdf
FEATURES
Fractional seconds
If provided, the number of seconds in time types is represented to microsecond accuracy. A full stop character is used as the decimal
seperator, which is allowed, but deprecated in preference to the comma character in ISO 8601:2004.
BUGS
Probably full of them, patches are very welcome.
Specifically missing features:
o No timezone support - all times are assumed UTC
o No week number type
o "Basic format", which lacks seperator characters, is not supported for reading or writing.
o Tests are rubbish.
AUTHOR
Tomas Doran (t0m) "<bobtfish@bobtfish.net>"
Dave Lambley "<davel@state51.co.uk>"
The development of this code was sponsored by my employer <http://www.state51.co.uk>.
Contributors
Aaron Moses
COPYRIGHT
Copyright (c) 2009 Tomas Doran. Some rights reserved.
This program is free software; you can redistribute
it and/or modify it under the same terms as Perl itself.
perl v5.14.2 2012-05-11 MooseX::Types::ISO8601(3pm)