Forum Discussion
Multiply only some specific values within a column
Dear! good day first time I post but I could not solve a doubt. Nor do I know if you can or not.
I have a column with sales that belong to different chains, but some of these chains are without VAT and others with VAT, I need them all to be with VAT, (all within the same column), that is to say I have for example falabella and paris with sales with VAT and ripley without VAT and I need ripley to be with VAT included, how can I do it?
Hi Syndicate_Admin ,
I can't see the data in the screenshot you provided. But according to your description, I created a column to determine if the field chains is "Ripley", increase the sales tax, otherwise the value remains the same. The reference is as follows:
val_sales_result = IF ( CONTAINSSTRING ( 'Table'[chains], "Ripley" ), 'Table'[sales] + 'Table'[var], 'Table'[sales] )If you can't solve the problem, please point out the specific problem and provide a clear screenshot, and I will answer you as soon as possible.
Best Regards,
Henry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
2 Replies
- parry2kSuper User
Syndicate_Admin it is very hard to see small screenshot, it should be straightforward, add a new column:
Sales with VAT = IF ( <<logic to check where sales is not with vat>>, Table[Sale] + Table[Vat], Table[Sales] )✨ Follow us on LinkedIn
Check my latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡
- v-henryk-mstfCommunity Support
Hi Syndicate_Admin ,
I can't see the data in the screenshot you provided. But according to your description, I created a column to determine if the field chains is "Ripley", increase the sales tax, otherwise the value remains the same. The reference is as follows:
val_sales_result = IF ( CONTAINSSTRING ( 'Table'[chains], "Ripley" ), 'Table'[sales] + 'Table'[var], 'Table'[sales] )If you can't solve the problem, please point out the specific problem and provide a clear screenshot, and I will answer you as soon as possible.
Best Regards,
Henry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.