10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
i try to set linux date & time in specific format but it keep giving me error
Example :
date "+%d-%m-%C%y %H:%M:%S" -d "19-01-2017 00:05:01"
or
date +"%d-%m-%C%y %H:%M:%S" -d "19-01-2017 00:05:01"
keep giving me this error :
date: invalid date ‘19-01-2017 00:05:01'
Please use CODE tags... (7 Replies)
Discussion started by: umen
7 Replies
2. Shell Programming and Scripting
Hi,
I have a requirement to create a shell script(tcsh) that finds all the files in a directory having the file name containing date format "YYYYMMDDHHMM" and extract the date time part ""YYYYMMDDHHMM" for further processing.
Could you please have any idea on this.
trades_201604040000.out... (6 Replies)
Discussion started by: gopal.biswal
6 Replies
3. UNIX for Dummies Questions & Answers
Hi Unix Gurus,
I would like to rename several files in a Unix Directory . The filenames can have more than 1 underscore ( _ ) and the last underscore is always followed by a date in the format mmddyyyy. The Extension of the files can be .txt or .pdf or .xls etc and is case insensitive ie... (1 Reply)
Discussion started by: pchegoor
1 Replies
4. Shell Programming and Scripting
Hi All,
If i have a specific date say "20130619 01:02:02.123456" , what is the unix command to display in
CCYY-MM-DD.HH.MM.SS.mmmmmm format?
Thanks in Advance, (6 Replies)
Discussion started by: HemaV
6 Replies
5. Shell Programming and Scripting
Need to increment the date from "currentdate + 90days" inside the for loop (i=1 to i=50) (5 Replies)
Discussion started by: aroragaurav.84
5 Replies
6. Shell Programming and Scripting
hi experts,
my requirement is like this i need to develop a shell script to update date part with new incremental date time in file some 'X' which is kept at some server location incrementing every two hours.as i am new to this scripting i need support from u people,thanx in advance (1 Reply)
Discussion started by: amanmro
1 Replies
7. Shell Programming and Scripting
hi all,
I need help for incrementing time in hh:mm:ss format like for example :
when i have a values like 02:07:16 I want to increment this value with 5 secs till it reaches a condition.
Can someone help me with this.
Thanks in advance. (2 Replies)
Discussion started by: hitha87
2 Replies
8. Shell Programming and Scripting
I need to increment a date value through shell script.
Input value consist of start date and end date in DATE format of unix.
For eg.
I need increment a date value of 1/1/09 to 31/12/09 i.e for a whole yr.
The output must look like
1/1/09
2/2/09
.
.
.
31/1/09
.
.
1/2/09
.
28/2/09... (1 Reply)
Discussion started by: sunil087
1 Replies
9. Shell Programming and Scripting
I have a comma delimited log file which has the date as MM/DD/YY in the 2nd column, and HH:MM:SS in the 3rd column.
I need to change the date format to YYYY-MM-DD and merge it with the the time HH:MM:SS. How will I got about this?
Sample input
02/27/09,23:52:31
02/27/09,23:52:52... (3 Replies)
Discussion started by: hazno
3 Replies
10. Shell Programming and Scripting
Hi all,
I want to increment the date which is in the format "YYYYMMDD".
ex: If the date is 20010601
Increment should be: 20010602, 20010603 etc.,
Any help will be much appreciated.
Many Thanks and Regards,
Ganapati (4 Replies)
Discussion started by: ganapati
4 Replies
DateTime::Format::DateParse(3) User Contributed Perl Documentation DateTime::Format::DateParse(3)
NAME
DateTime::Format::DateParse - Parses Date::Parse compatible formats
SYNOPSIS
use DateTime::Format::DateParse;
my $dt = DateTime::Format::DateParse->parse_datetime( $date );
my $dt = DateTime::Format::DateParse->parse_datetime( $date, $zone );
DESCRIPTION
This module is a compatibility wrapper around Date::Parse.
USAGE
Import Parameters
This module accepts no arguments to it's "import" method and exports no symbols.
Methods
Class Methods
o parse_datetime($date [, $zone])
Accepts a Date::Parse compatible $date string and optionally a Time::Zone compatible $zone string.
Returns a DateTime object.
GOTCHAS
o If parse_datetime is called on a $date that doesn't know specify a timezone and $zone is not set, then the timezone of the returned
DateTime object will be set to the "local" timezone. This is consistent with the behavior of Date::Parse.
o If parse_datetime is called without a $zone but the $date string does specify a timezone/offset or if parse_datetime is called with a
$zone that DateTime::TimeZone does not understand, the returned DateTime object will have it's timezone set to a fixed offset from UTC.
This means that "DST" information is not available and date math will not reflect "DST" transitions. This may be resolved for true
timezones by using the DateTime::TimeZone::Alias module to "alias" the Time::Zone timezone to an Olson DB name. This may be done
automatically in a future release.
CREDITS
Graham Barr (GBARR) <gbarr@pobox.com>, author of Date::Parse
Everyone at the DateTime "Asylum".
SUPPORT
Support for this module is provided via the <datetime@perl.org> email list. See <http://lists.perl.org/> for more details.
AUTHOR
Joshua Hoblitt (JHOBLITT) <jhoblitt@cpan.org>
COPYRIGHT
Copyright (c) 2005-6 Joshua Hoblitt. All rights reserved. This program is free software; you can redistribute it and/or modify it under
the same terms as Perl itself.
The full text of the licenses can be found in the LICENSE file included with this module, or in perlartistic and perlgpl as supplied with
Perl 5.8.1 and later.
SEE ALSO
Date::Parse, Time::Zone, DateTime, DateTime::TimeZone, DateTime::TimeZone::Alias, <http://datetime.perl.org/>
perl v5.16.3 2014-06-10 DateTime::Format::DateParse(3)