Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Community,
I have a problem with a straight table and not sure if I am going in the right direction.
I would like a straight table that shows the main costs and the additional costs for that company ignoring any other additional costs from other companies
I have 2 tables one with the main purchase and another table with additional purchases
looks a bit like this
Flight ID | Company No. | Net Cost |
123456 | AMERICA | 5000 |
Flight ID | Buy From No | Add Costs | Sent to Accounts |
123456 | FLL | 1,000.28 | Yes |
123456 | AMERICA | 5,065.12 | Yes |
123456 | AMERICA | 465.3 | Yes |
123456 | REP/GODFREY | 830 | Yes |
What I would like to see in a straight table is
Flight ID | Company No. | Net Costs | Additional Cost |
123456 | AMERICA | 5000 | 6,065.40 |
This just shows the costs and additional costs of the company.
But I get
Flight ID | Company No. | Net Costs | Additional Cost |
123456 | AMERICA | 5000 | 7,360.70 |
Which is the total of the all the other companies and not just the main company.
For this one I did this
(SUM({$<[Sent to Accounts]={'1'}>}[Additional Cost]))
Then I tried adding some set analysis / variable (I don't realty understand them all that well, so I am completely doing it wrong)
(SUM({$<[Operator No.]={$(=only(Operator No.))},[Sent to Accounts]={'1'}>}[Additional Cost]))
I just get 0 as a result.
I hope this is clear enough, please get in touch if you need any more information
Thank you for your time
Mark
The following expression should also work using the Possible values function.
sum({<SentToAccounts={'Yes'}, BuyFromNo=P(CompanyNo)>}AddCosts)
Regards,
Srikanth