Sponsored Content
Full Discussion: date conversion
Top Forums Shell Programming and Scripting date conversion Post 302181459 by danmero on Thursday 3rd of April 2008 03:45:00 AM
Old 04-03-2008
PHP

Quote:
Originally Posted by charandevu
it is not working.......
file1
E108,0,2/3/1995,0,E001,E003,A,15000,1250,7.211538
E109,0,2/15/1995,0,E001,E001,A,78000,6500,37.5
E110,0,10/12/1995,0,E001,E001,A,56000,4666.667,26.923077

I wann to convert the this file1 to file2

E108,0,199523,0,E001,E003,A,15000,1250,7.211538
E109,0,1995215,0,E001,E001,A,78000,6500,37.5
E110,0,19951012,0,E001,E001,A,56000,4666.667,26.923077


and on this file i am going to do more process like sort and compare.....with other files which has this date format...........


And is it possible to hold the date value in a string variable while reading from a file..........i am here with developing a tool which should process within a min......And i am new to unix.


Please let me know on this how to do that..........asap
You have another thread for this subject
https://www.unix.com/shell-programmin...9213-date.html
and vgersh99 already provide the solution:
https://www.unix.com/302181187-post11.html
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Date Conversion

Hello, I want to convert MM DD YYYY date format to MM-DD-YYYY format. For exemple: I have to convert Nov 28 2005 to 28-11-2005. Thenks for youf help. DAFI (2 Replies)
Discussion started by: dafidak
2 Replies

2. Shell Programming and Scripting

date conversion

Hi everybody: Could anybody tell me how I convert from a julian date, with shell comands, to gregorian. Thanks in advance. (2 Replies)
Discussion started by: tonet
2 Replies

3. Shell Programming and Scripting

Date Conversion

Hi, Does anyone know (in KSH, CSH, SED or AWK), how to convert date text in a file from: EX: May232008 to: 05232008 Thanks, (3 Replies)
Discussion started by: jgrant746
3 Replies

4. Shell Programming and Scripting

Date conversion

Hi I want to convert MAY 05 2005 01:15:00PM date format to 2005/05/05 01:15:00PM . CAn somebody suggest me a code ,I am new to unix shell programming. Thanks Arif (21 Replies)
Discussion started by: mab_arif16
21 Replies

5. Shell Programming and Scripting

Date conversion

Hi, I have the string YYYYMMDDHHMMSS like 20090801204150 and I need to convert it using the unix command date in the format: date "Saturday, 1 August 2009 20:40:59" All in one single Unix line if this is possible. What's the correct syntax? Steve Hagi (6 Replies)
Discussion started by: hagimeno
6 Replies

6. Shell Programming and Scripting

Conversion of date to Julian date

Hi Gurus, Need help in Conversion of date(2007-11-30) to Julian date(YYDDD)... '+%J' 2007-11-30 to 'YYDDD' Thanks (4 Replies)
Discussion started by: SeenuGuddu
4 Replies

7. UNIX for Dummies Questions & Answers

Date conversion in ab i

(string(8)) ((date("YYYYMMDD")) ((date("YYYY/MM/DD")) in.date_field_name)) (1 Reply)
Discussion started by: dr46014
1 Replies

8. Shell Programming and Scripting

Julian date to Calendar date conversion

Hi all, I require to convert julian date to normal calander date in unix for eg julian date=122 now i want corresponding calander date ---------------------------------------- gr8 if give very small command/script and please explain the steps as well(imp) Thanks ... (3 Replies)
Discussion started by: RahulJoshi
3 Replies

9. Shell Programming and Scripting

Date conversion

Trying to convert dates using a Perl Script but it has to accept formats like 3 letter month, day and year like Nov 02 2010 or 1/4/11 or 21 Feb 2011 and have it convert to something like October 20, 2011. Any ideas? (2 Replies)
Discussion started by: reduxeffect81
2 Replies

10. UNIX for Beginners Questions & Answers

Date conversion

Hi , we have a string with yyyymmdd format . how to know which date it is ? example:20120712-->sunday 20150228-->saturday 20140431-->invalid please suggest commands which work on below os : SunOS 5.10 shell: bash shell Thanks, Srinath. (10 Replies)
Discussion started by: srinadhreddy27
10 Replies
DateTime::Locale::kl_GL(3)				User Contributed Perl Documentation				DateTime::Locale::kl_GL(3)

NAME
DateTime::Locale::kl_GL SYNOPSIS
use DateTime; my $dt = DateTime->now( locale => 'kl_GL' ); print $dt->month_name(); DESCRIPTION
This is the DateTime locale package for Kalaallisut Greenland. DATA
This locale inherits from the DateTime::Locale::kl locale. It contains the following data. Days Wide (format) ataasinngorneq marlunngorneq pingasunngorneq sisamanngorneq tallimanngorneq arfininngorneq sabaat Abbreviated (format) ata mar pin sis tal arf sab Narrow (format) 2 3 4 5 6 7 1 Wide (stand-alone) ataasinngorneq marlunngorneq pingasunngorneq sisamanngorneq tallimanngorneq arfininngorneq sabaat Abbreviated (stand-alone) ata mar pin sis tal arf sab Narrow (stand-alone) 2 3 4 5 6 7 1 Months Wide (format) januari februari martsi aprili maji juni juli augustusi septemberi oktoberi novemberi decemberi Abbreviated (format) jan feb mar apr maj jun jul aug sep okt nov dec Narrow (format) 1 2 3 4 5 6 7 8 9 10 11 12 Wide (stand-alone) januari februari martsi aprili maji juni juli augustusi septemberi oktoberi novemberi decemberi Abbreviated (stand-alone) jan feb mar apr maj jun jul aug sep okt nov dec Narrow (stand-alone) 1 2 3 4 5 6 7 8 9 10 11 12 Quarters Wide (format) Q1 Q2 Q3 Q4 Abbreviated (format) Q1 Q2 Q3 Q4 Narrow (format) 1 2 3 4 Wide (stand-alone) Q1 Q2 Q3 Q4 Abbreviated (stand-alone) Q1 Q2 Q3 Q4 Narrow (stand-alone) 1 2 3 4 Eras Wide BCE CE Abbreviated BCE CE Narrow BCE CE Date Formats Full 2008-02-05T18:30:30 = marlunngorneq 05 februari 2008 1995-12-22T09:05:02 = tallimanngorneq 22 decemberi 1995 -0010-09-15T04:44:23 = arfininngorneq 15 septemberi -10 Long 2008-02-05T18:30:30 = 05 februari 2008 1995-12-22T09:05:02 = 22 decemberi 1995 -0010-09-15T04:44:23 = 15 septemberi -10 Medium 2008-02-05T18:30:30 = feb 05, 2008 1995-12-22T09:05:02 = dec 22, 1995 -0010-09-15T04:44:23 = sep 15, -10 Short 2008-02-05T18:30:30 = 05/02/08 1995-12-22T09:05:02 = 22/12/95 -0010-09-15T04:44:23 = 15/09/-10 Default 2008-02-05T18:30:30 = feb 05, 2008 1995-12-22T09:05:02 = dec 22, 1995 -0010-09-15T04:44:23 = sep 15, -10 Time Formats Full 2008-02-05T18:30:30 = 6:30:30 PM UTC 1995-12-22T09:05:02 = 9:05:02 AM UTC -0010-09-15T04:44:23 = 4:44:23 AM UTC Long 2008-02-05T18:30:30 = 6:30:30 PM UTC 1995-12-22T09:05:02 = 9:05:02 AM UTC -0010-09-15T04:44:23 = 4:44:23 AM UTC Medium 2008-02-05T18:30:30 = 6:30:30 PM 1995-12-22T09:05:02 = 9:05:02 AM -0010-09-15T04:44:23 = 4:44:23 AM Short 2008-02-05T18:30:30 = 6:30 PM 1995-12-22T09:05:02 = 9:05 AM -0010-09-15T04:44:23 = 4:44 AM Default 2008-02-05T18:30:30 = 6:30:30 PM 1995-12-22T09:05:02 = 9:05:02 AM -0010-09-15T04:44:23 = 4:44:23 AM Datetime Formats Full 2008-02-05T18:30:30 = marlunngorneq 05 februari 2008 6:30:30 PM UTC 1995-12-22T09:05:02 = tallimanngorneq 22 decemberi 1995 9:05:02 AM UTC -0010-09-15T04:44:23 = arfininngorneq 15 septemberi -10 4:44:23 AM UTC Long 2008-02-05T18:30:30 = 05 februari 2008 6:30:30 PM UTC 1995-12-22T09:05:02 = 22 decemberi 1995 9:05:02 AM UTC -0010-09-15T04:44:23 = 15 septemberi -10 4:44:23 AM UTC Medium 2008-02-05T18:30:30 = feb 05, 2008 6:30:30 PM 1995-12-22T09:05:02 = dec 22, 1995 9:05:02 AM -0010-09-15T04:44:23 = sep 15, -10 4:44:23 AM Short 2008-02-05T18:30:30 = 05/02/08 6:30 PM 1995-12-22T09:05:02 = 22/12/95 9:05 AM -0010-09-15T04:44:23 = 15/09/-10 4:44 AM Default 2008-02-05T18:30:30 = feb 05, 2008 6:30:30 PM 1995-12-22T09:05:02 = dec 22, 1995 9:05:02 AM -0010-09-15T04:44:23 = sep 15, -10 4:44:23 AM Available Formats d (d) 2008-02-05T18:30:30 = 5 1995-12-22T09:05:02 = 22 -0010-09-15T04:44:23 = 15 EEEd (d EEE) 2008-02-05T18:30:30 = 5 mar 1995-12-22T09:05:02 = 22 tal -0010-09-15T04:44:23 = 15 arf Hm (H:mm) 2008-02-05T18:30:30 = 18:30 1995-12-22T09:05:02 = 9:05 -0010-09-15T04:44:23 = 4:44 hm (h:mm a) 2008-02-05T18:30:30 = 6:30 PM 1995-12-22T09:05:02 = 9:05 AM -0010-09-15T04:44:23 = 4:44 AM Hms (H:mm:ss) 2008-02-05T18:30:30 = 18:30:30 1995-12-22T09:05:02 = 9:05:02 -0010-09-15T04:44:23 = 4:44:23 hms (h:mm:ss a) 2008-02-05T18:30:30 = 6:30:30 PM 1995-12-22T09:05:02 = 9:05:02 AM -0010-09-15T04:44:23 = 4:44:23 AM M (L) 2008-02-05T18:30:30 = 2 1995-12-22T09:05:02 = 12 -0010-09-15T04:44:23 = 9 Md (M-d) 2008-02-05T18:30:30 = 2-5 1995-12-22T09:05:02 = 12-22 -0010-09-15T04:44:23 = 9-15 MEd (E, M-d) 2008-02-05T18:30:30 = mar, 2-5 1995-12-22T09:05:02 = tal, 12-22 -0010-09-15T04:44:23 = arf, 9-15 MMdd (dd/MM) 2008-02-05T18:30:30 = 05/02 1995-12-22T09:05:02 = 22/12 -0010-09-15T04:44:23 = 15/09 MMM (LLL) 2008-02-05T18:30:30 = feb 1995-12-22T09:05:02 = dec -0010-09-15T04:44:23 = sep MMMd (MMM d) 2008-02-05T18:30:30 = feb 5 1995-12-22T09:05:02 = dec 22 -0010-09-15T04:44:23 = sep 15 MMMEd (E MMM d) 2008-02-05T18:30:30 = mar feb 5 1995-12-22T09:05:02 = tal dec 22 -0010-09-15T04:44:23 = arf sep 15 MMMMd (MMMM d) 2008-02-05T18:30:30 = februari 5 1995-12-22T09:05:02 = decemberi 22 -0010-09-15T04:44:23 = septemberi 15 MMMMdd (dd MMMM) 2008-02-05T18:30:30 = 05 februari 1995-12-22T09:05:02 = 22 decemberi -0010-09-15T04:44:23 = 15 septemberi MMMMEd (E MMMM d) 2008-02-05T18:30:30 = mar februari 5 1995-12-22T09:05:02 = tal decemberi 22 -0010-09-15T04:44:23 = arf septemberi 15 ms (mm:ss) 2008-02-05T18:30:30 = 30:30 1995-12-22T09:05:02 = 05:02 -0010-09-15T04:44:23 = 44:23 y (y) 2008-02-05T18:30:30 = 2008 1995-12-22T09:05:02 = 1995 -0010-09-15T04:44:23 = -10 yM (y-M) 2008-02-05T18:30:30 = 2008-2 1995-12-22T09:05:02 = 1995-12 -0010-09-15T04:44:23 = -10-9 yMEd (EEE, y-M-d) 2008-02-05T18:30:30 = mar, 2008-2-5 1995-12-22T09:05:02 = tal, 1995-12-22 -0010-09-15T04:44:23 = arf, -10-9-15 yMMM (y MMM) 2008-02-05T18:30:30 = 2008 feb 1995-12-22T09:05:02 = 1995 dec -0010-09-15T04:44:23 = -10 sep yMMMEd (EEE, y MMM d) 2008-02-05T18:30:30 = mar, 2008 feb 5 1995-12-22T09:05:02 = tal, 1995 dec 22 -0010-09-15T04:44:23 = arf, -10 sep 15 yMMMM (y MMMM) 2008-02-05T18:30:30 = 2008 februari 1995-12-22T09:05:02 = 1995 decemberi -0010-09-15T04:44:23 = -10 septemberi yQ (y Q) 2008-02-05T18:30:30 = 2008 1 1995-12-22T09:05:02 = 1995 4 -0010-09-15T04:44:23 = -10 3 yQQQ (y QQQ) 2008-02-05T18:30:30 = 2008 Q1 1995-12-22T09:05:02 = 1995 Q4 -0010-09-15T04:44:23 = -10 Q3 yyMM (MM/yy) 2008-02-05T18:30:30 = 02/08 1995-12-22T09:05:02 = 12/95 -0010-09-15T04:44:23 = 09/-10 yyQ (Q yy) 2008-02-05T18:30:30 = 1 08 1995-12-22T09:05:02 = 4 95 -0010-09-15T04:44:23 = 3 -10 yyyyMMMM (MMMM y) 2008-02-05T18:30:30 = februari 2008 1995-12-22T09:05:02 = decemberi 1995 -0010-09-15T04:44:23 = septemberi -10 Miscellaneous Prefers 24 hour time? No Local first day of the week sabaat SUPPORT
See DateTime::Locale. AUTHOR
Dave Rolsky <autarch@urth.org> COPYRIGHT
Copyright (c) 2008 David Rolsky. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. This module was generated from data provided by the CLDR project, see the LICENSE.cldr in this distribution for details on the CLDR data's license. perl v5.18.2 2017-10-06 DateTime::Locale::kl_GL(3)
All times are GMT -4. The time now is 07:09 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy