Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
George1973
Helper V
Helper V

Accompanied Products Sales Frequency

Hi Folks,

I need to get a list of Goods pared (accompanied) with the FOCUSED group of products and namely their frequency in order to get the most frequntly demanded "Package of Goods" sold.

Well, I have looked in the forum and found something similar with two independent tables, one for the products and one for the orders and have tried to use this solution:

George1973_0-1687873669240.png

Then created the following measure:

Pared_Codes (Count) = 
// Measure for Orders
var _1=SELECTCOLUMNS(FILTER(ALL(TS_OPERATIONS_DOP2),TS_OPERATIONS_DOP2[GOODS_KOD] in SELECTCOLUMNS(ALLSELECTED(C_GOODS),"1",C_GOODS[Good_ID])),"1",TS_OPERATIONS_DOP2[IDLINK])
VAR OrdRs=IF(MAX(TS_OPERATIONS_DOP2[IDLINK]) in _1,1,0)

// Measure for Goods
var _selected=SELECTCOLUMNS(ALLSELECTED(C_GOODS),"1",C_GOODS[Good_ID])
VAR GoodsRes=IF(MAX(C_GOODS[Good_ID]) in _selected,0,1)

return
IF(OrdRs=GoodsRes,DISTINCTCOUNT(TS_OPERATIONS_DOP2[IDLINK]),BLANK())


As a result I'm getting the matrix like this:

George1973_1-1687874065449.png

(Note: There are only 3 "FOCUSED" Goods selected)

The result seems to work partialy, meaning that: There is filter working per accompaning products codes, but for cross filter does not work..

Please advise the proper solution.

Thanks in advance,

 

 

 

 

 

 

 




0 REPLIES 0

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.