10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
Hi All,
I have a CSV file which is as below. Basically I need to take the year column in it and find if the year is >= 20152 . If that is then I should subtract all values by 6. In the below example in description I am having number mentioned as YYWW so I need to subtract those by -5. Whereever... (8 Replies)
Discussion started by: arunkumar_mca
8 Replies
2. Shell Programming and Scripting
Hi,
We have csv file where date is coming in MM/DD/YYYY HH:MM:SS (06/23/2015 20:59:12) in multiple places
But we need to change the date format to DD/Mon/YYYY HH:MM:SS (23/Jul/2015 20:59:12) using shell script.
Please let us know how can we achieve the same. (16 Replies)
Discussion started by: dholea
16 Replies
3. Shell Programming and Scripting
Example:
Input csv file
00245DLS,Sitel Ocala,12/31/2014,18:45,1.00,7.00,0.00,0.00
00245DLS,Sitel Ocala,12/31/2014,19:00,-1.00,-1.00,-1.00,-1.00
00245HB,Charlotte,01/01/2015,00:00,-1.00,-1.00,-1.00,0.00
Output csv file
00245DLS,Sitel Ocala,2014/12/31,18:45,1.00,7.00,0.00,0.00
00245DLS,Sitel... (8 Replies)
Discussion started by: adit
8 Replies
4. Shell Programming and Scripting
How can i make the date command output yesterday's date, current date and the date 4 days ago, in the following format:
2012-10-03
code:
date +% ???? (3 Replies)
Discussion started by: SkySmart
3 Replies
5. Shell Programming and Scripting
Hi all,
I have a file with below data
af23b|11-FEB-12|acc7
ad23b|12-JAN-12|acc4
as23b|15-DEC-11|acc5
z123b|18-FEB-12|acc1
I need the output as below:-(date in yyyymmdd format)
af23b|20120211|acc7
ad23b|20120112|acc4
as23b|20111215|acc5
z123b|20120218|acc1
Please help me on this.... (7 Replies)
Discussion started by: gani_85
7 Replies
6. Shell Programming and Scripting
Hi...
I have an inputfile name as :- abc_test_20120213.dat (date in yyyymmdd format)
I need the output file name as abc_test_13022012.dat (date in ddmmyyyy format)
Please help me on this...
Thanks in advance. (5 Replies)
Discussion started by: gani_85
5 Replies
7. UNIX for Dummies Questions & Answers
I have a list of dates in the following format: mm/dd/yyyy and want to change these to the MySQL standard format: yyyy-mm-dd.
The dates in the original file may or may not be zero padded, so April is sometimes "04" and other times simply "4".
This is what I use to change the format:
sed -i '' -e... (2 Replies)
Discussion started by: figaro
2 Replies
8. Shell Programming and Scripting
So I have a csv file where the 3rd field is a date string in the format yyyy-mm-dd. I need to change it to mm/dd/yyyy. So each line in the csv file looks like:
StringData,StringData,2009-02-17,12.345,StringData
StringData,StringData,2009-02-16,65.789,StringData
Any idea how I can keep... (5 Replies)
Discussion started by: rpiller
5 Replies
9. Shell Programming and Scripting
Hi Experts,
Please help me to get the following from script for Unix ENvironment(shell, perl, tr, sed, awk).
INPUT FILE:
20K,ME,592971
20K,YOU,2
20K,HE,1244998
50K,YOU,480110
50K,ME,17
50K,HIS,10
50K,HE,1370391
OUTPUT FILE:
K,ME,YOU,HE,HIS
20K,592971,2,1244998,0... (5 Replies)
Discussion started by: ashis.tewari
5 Replies
10. UNIX for Dummies Questions & Answers
Hi,
There are lots of threads about how to manipulate the date using date +%m %.......
But how can I change the default format of the commad date?
$ date
Mon Apr 10 10:57:15 BST 2006
This would be on fedora and SunOs.
Cheers,
Neil (4 Replies)
Discussion started by: nhatch
4 Replies