I am trying to convert SQL file to CSV format and using unix/linux command to do so.
I am stuck at a place where I have to transform few colomns from 02-09-2013
or 02/09/2013
to 09-FEB-2013
.
SQL File looks like:
INSERT INTO PRODMETH(ITEM, LOC, PRODUCTIONMETHOD, DESCR, EFF, PRIORITY, MINQTY, INCQTY,
DISC, LEADTIME, MAXQTY, OFFSETTYPE)
VALUES ('ABCD','PLANT','RT_ABCD_PLANT','Sort2B',TO_DATE('01/01/1970 12:00:00 AM','MM/DD/YYYY HH:MI:SS AM'),'1','0','0',
TO_DATE('01/01/1970 12:00:00 AM','MM/DD/YYYY HH:MI:SS AM'),'0','0','1');
I am looking for a bash command which would read file and change all occurrence of mm/dd/yyyy
to dd-MON-yyyy
.