Subtracting and adding Julian dates



IBM's Command List programming language & Restructured Extended Executor

Subtracting and adding Julian dates

Postby Arun kumar rajesh » Wed May 11, 2011 1:39 pm

Hi all,

I am coding a tool using REXX. My need is to convert the julian date to Gregorian.
Before that i need to subtract 7 days from the current julian date and from that date i need to add 5 days.Then to convert it.
I need only the subtraction and addition coding format. Please help in this
Arun kumar rajesh
 
Posts: 2
Joined: Wed Jan 05, 2011 8:26 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Subtracting and adding Julian dates

Postby prino » Wed May 11, 2011 2:02 pm

And where are you stuck? Please show us your code!
Robert AH Prins
robert.ah.prins @ the.17+Gb.Google thingy
User avatar
prino
 
Posts: 635
Joined: Wed Mar 11, 2009 12:22 am
Location: Vilnius, Lithuania
Has thanked: 3 times
Been thanked: 28 times

Re: Subtracting and adding Julian dates

Postby enrico-sorichetti » Wed May 11, 2011 2:02 pm

read the REXX manuals about the DATE builtin function and it' s conversion capabilities here
http://publibz.boulder.ibm.com/cgi-bin/ ... s/IKJ4BK90

hint ...
to carry on arithmetics on dates use the BASE DATE representation

I wonder about the wannabe tool writers who do not care/have the skill to find the most basic info on the language they use :evil:
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 2994
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 164 times

Re: Subtracting and adding Julian dates

Postby Arun kumar rajesh » Thu May 12, 2011 4:21 pm

Hi enrico,
Thanks for your reference. Sorry for that. This is my first tool. So I am not aware of it. I am beginner soon i ll try to catch all.
Arun kumar rajesh
 
Posts: 2
Joined: Wed Jan 05, 2011 8:26 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Subtracting and adding Julian dates

Postby enrico-sorichetti » Thu May 12, 2011 8:55 pm

before attempting to write tools You should have a better knowledge of the <language> You will use to implement them !
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 2994
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 164 times

Re: Subtracting and adding Julian dates

Postby MrSpock » Thu May 12, 2011 10:00 pm

Arun kumar rajesh wrote:Before that i need to subtract 7 days from the current julian date and from that date i need to add 5 days.Then to convert it.


I don't understand this. Why not just subtract 2 days?
User avatar
MrSpock
Global moderator
 
Posts: 807
Joined: Wed Jun 06, 2007 9:37 pm
Location: Raleigh NC USA
Has thanked: 0 time
Been thanked: 4 times


Return to CLIST & REXX

 


  • Related topics
    Replies
    Views
    Last post