Interview Answer

If McDonalds were run like a software company, one out of every hundred Big Macs would give you food poisoning, and the response would be, ‘We’re sorry, here’s a coupon for two more.’ “ Mark Minasi

How to get Julian date Oracle

April 12, 2016 7:25 pm

Comments



How to get Julian date Oracle


select the Julian date for current date.


Solution

   					 
												SQL > select to_char(sysdate,’J’) as julian from dual; 

												-- Convert date to Julian date 
												SQL > select to_char(to_date(’24-Jan-2013?,’dd-mon-yyyy’),’J’) as julian from dual;
												SQL > select to_char(to_date(’01-Jan-4712 BC’,’dd-mon-yyyy AD’),’J’) as julian from dual;
																    

Comments



Please login to add comments.