12 Replies Latest reply on May 18, 2017 3:01 AM by Deepak G S

# I want to show the total no of unprofitable days each month.

Hi all,

I am trying to show the number of unprofitable days each month not only by color, but also by showing a total of such unprofitable days for each month. I am new and will greatly appreciate all the help.

I have attached a v9,3 workbook. Thanks.

Udy.

• ###### 1. Re: I want to show the total no of unprofitable days each month.

Hi Uduak,

You can calculate non-profit days by using below formulas

Non-Profit-Days : { FIXED [Order Date] : sum([Profit])<0 } - This will flag each day if it has Negative Profit

Non-Profit-Days (Count) : Simply count how many days with negative profit using above formula

IF [Non-Profit-Days] then

[Order Date]

END

I have attached DEMO for your reference. let me know if you still have any doubt.

Hope this helps!

Thanks,

Nikunj

• ###### 2. Re: I want to show the total no of unprofitable days each month.

Is this what you are looking for ?

Create 2 calculations positive and Negative as :

Positive :{ FIXED [Order Date] : IF SUM([Profit])>0 THEN 1 end }

Negative :{ FIXED [Order Date] : IF SUM([Profit])<0 THEN 1 end }

take out Order date from Rows shelf so that your view will be at Month level.

• ###### 3. Re: I want to show the total no of unprofitable days each month.

Hi Hima,

Thanks a lot for your help. Please take a look at the attached screenshot: Can you show me how I can achieve that?

• ###### 4. Re: I want to show the total no of unprofitable days each month.

Hi ,

In the attached screenshot you are already showing Profitable and Non Profitable Days for each month right ?

just use this calculations if you need it :

Profitable        : { FIXED [Order Date] : IF SUM([Profit])>0 THEN 1 end }

Non Profitable  :{ FIXED [Order Date] : IF SUM([Profit])<0 THEN 1 end }

• ###### 5. Re: I want to show the total no of unprofitable days each month.

Yes the attached screenshot shows profitable and unprofitable days, but I didn't create it. I am trying to create it.

• ###### 6. Re: I want to show the total no of unprofitable days each month.

Use these calculations to get counts :

Profitable        : { FIXED [Order Date] : IF SUM([Profit])>0 THEN 1 end }

Non Profitable  :{ FIXED [Order Date] : IF SUM([Profit])<0 THEN 1 end }

Drag these 2 calculations into Columns shelf and drag measure names into color shelf and select suitable colors for values Profitable and Non Profitable values.

attaching the workbook edited in 10 version for reference .

3 of 3 people found this helpful
• ###### 7. Re: I want to show the total no of unprofitable days each month.

Hi,

Check attached workbook.

Thanks

Nikunj

• ###### 8. Re: I want to show the total no of unprofitable days each month.

Thank you Hima! This is perfect!

• ###### 9. Re: I want to show the total no of unprofitable days each month.

Hi Nikunj,

I can't the workbook you attached.

Thanks.

Udy

• ###### 10. Re: I want to show the total no of unprofitable days each month.

Ya, its almost same like what Hema did. i changed workbook to 10.0 version. try if you can see it.

2 of 2 people found this helpful
• ###### 11. Re: I want to show the total no of unprofitable days each month.

Nikunj I have seen the workbook and it's perfect! Thanks a lot!

• ###### 12. Re: I want to show the total no of unprofitable days each month.

{fixed [order date] : if sum(profit)>0 then 1 else 0 end} - Calculate the profit days  - A

{fixed [order date] : if sum(profit)<0 then 1 else 0 end} - Calculate the non-profit days(negative days) - B

Ratio:

A:B