Sponsored Content
Full Discussion: Convert date to Unix format
Top Forums Shell Programming and Scripting Convert date to Unix format Post 302510959 by yahyaaa on Tuesday 5th of April 2011 11:26:57 AM
Old 04-05-2011
Quote:
Originally Posted by DukeNuke2
try this:

Code:
perl -e 'print time . "\n"'

Thanks... What if I need it for predefined time ?

---------- Post updated at 10:25 AM ---------- Previous update was at 10:20 AM ----------

Thank you

---------- Post updated at 10:26 AM ---------- Previous update was at 10:25 AM ----------

I never heard of ksh93, how to use it as i tried it on solaris 10 but not found
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

convert mmddyy date format to ccyyddd format??

hi, for reading a cobol indexed file i need to convert "mmddyy" date format to "ccyyddd" format. i checked the datecalc and other scripts but couldnt modify them to cater to my need:(... The datecalc gives an output which i believe is the total days till that date, but i want to convert it... (2 Replies)
Discussion started by: Bhups
2 Replies

2. UNIX for Dummies Questions & Answers

Convert date format

Hi All, Need your help in converting a date format in ksh. I'm currently working on SUN os where my script is getting a date from a table. The result returns to ksh in this format: 17-JUL-08 How do i convert this string to a date format like yyyymmdd? I tried #!/bin/ksh d="17-JUL-08"... (5 Replies)
Discussion started by: agathaeleanor
5 Replies

3. Shell Programming and Scripting

convert unix date to readable format

Dear Experts, I need your help to convert a unix date and time format number in to readable format like dd/mm/yyyy . I have a text file of more than 10,000 records and it is like NAME DATE1 COUNTRY DATE2 ABD 1223580395699 USA 1223580395699... (3 Replies)
Discussion started by: shary
3 Replies

4. Shell Programming and Scripting

convert date format to mysql date format in log file

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

5. Shell Programming and Scripting

To convert a date(in string format) to unix timestamp

Hi All, I have a string like below. "Mar 31 2009" . I want to convert this to unix time . Also please let me know how to find the unix time for the above string minus one day. For Eg. if i have string "Mar 31 2009" i want to find the unix time stamp of "Mar 30 2009". Thanks in advance,... (11 Replies)
Discussion started by: girish.raos
11 Replies

6. Shell Programming and Scripting

convert date format

I've been using this thread: https://www.unix.com/shell-programming-scripting/58675-change-date-dd-mmm-yyyy-mm-dd-yyyy.html and https://www.unix.com/shell-programming-scripting/14655-changing-yyyy-mm-dd-ddmmyy.html and this code: on this format: 05/16/2008 18:30:49 Installation 48985and I'm... (3 Replies)
Discussion started by: dba_frog
3 Replies

7. Shell Programming and Scripting

Need a unix script to convert date into Julian format in a text file

The 6th & 7th column of the text files represents date & time. I need this to be converted in julian format using command "date +%s -d <date>". I know the command, but dont know how to use it on the script 0 dbclstr-b IXT_Web Memphis_Prod_SQL_Full Memphis-Prod-SQL-Full-Application-Backup... (4 Replies)
Discussion started by: ajiwww
4 Replies

8. UNIX for Dummies Questions & Answers

Rename all Files in a UNIX Directory from one date format to another date format

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

9. Shell Programming and Scripting

Convert Date Format

Hello, I want to change the format of date value in variable. e.g. cur_date = '2013/03/13 14:24:50' (yyyy/mm/dd hh24:mi:ss) I want to change this to '13-MAR-2013 14:24:50 Following code coverts the current date to format I am looking for. But I do not know how this can be done for a date... (8 Replies)
Discussion started by: cartrider
8 Replies

10. Shell Programming and Scripting

Convert date in dd mm yyyy format to UNIX timestamp

Hello All, I have a date in DD/MM/YYYY format. I am trying to convert this into unix timestamp. I have tried following: date -d $mydate +%s where mydate = 23/12/2016 00:00:00 I am getting following error: date: extra operand `+%s' Try `date --help' for more information. ... (1 Reply)
Discussion started by: angshuman
1 Replies
fuse-utils(1)							     Emulators							     fuse-utils(1)

NAME
fuse-utils - various ZX Spectrum related utilities DESCRIPTION
The Fuse (Free Unix Spectrum Emulator) utilities are a small suite of utilities relating to some of the file formats used by ZX Spectrum emulators. The currently available utilities are: audio2tape Convert an audio file into a tape format. createhdf Create a blank IDE hard disk image in .hdf format. listbasic Extract the BASIC program from a ZX Spectrum file. profile2map Convert Fuse profiler output into Z80-style map format. raw2hdf Create an .hdf hard disk image from a raw data file. rzxcheck Verify the `competition mode' signature in an RZX input recording file. rzxdump Display the contents of an RZX file. rzxtool Make simple modifications to an RZX file. scl2trd Convert .scl disk images into .trd format. snap2tzx Convert a snapshot into a .tzx tape image. snapconv Convert between various snapshot formats. tape2wav Convert a tape file into .wav audio format. tapeconv Convert between various tape formats. tzxlist Display the contents of a .tzx tape image. SEE ALSO
audio2tape(1), createhdf(1), fuse(1), libspectrum(3), listbasic(1), raw2hdf(1), rzxcheck(1), rzxdump(1), rzxtool(1), scl2trd(1), snap2tzx(1), snapconv(1), tape2wav(1), tapeconv(1), tzxlist(1), xspect(1), xzx(1) The comp.sys.sinclair Spectrum FAQ, at http://www.worldofspectrum.org/faq/index.html. AUTHOR
Philip Kendall (philip-fuse@shadowmagic.org.uk) and others; see the individual man pages for more details. Version 1.0.0 16th December, 2010 fuse-utils(1)
All times are GMT -4. The time now is 11:12 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy