Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Microstrategy Apply Simple Week calculation

Status
Not open for further replies.

RosaNegra

Programmer
Jan 21, 2013
1
US
I need some help with some logic regarding week calculation.
I have an attribute Task. Task has it's duration (number of weeks in format 201239).
And I have a metric that returns id of current week (today's date -7).
I need ti calculate remaining weeks till the end of the task.
It all works great until we enter next year.

example: Task week 201240 | Task duration 201338
and instead of returning 50 weeks that are left until the end of the task, it returns some wrong number.

I could really use some help regarding this.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top