March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe 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
Hello everybody,
I'm discovering DAX language and I have some difficulties to do thant I want.
I will explain you my issue.
in the field "Prodline", I don't have always value, I have only one when "MvtType" is 101.
I would like to complete Field "Prodline" when data is missing and take data when "ProdOrder" is same
I tried to mix together function IF and LookUpValue but It's not working
You can find an extract of my table below
Thanks you a lot.
Regards 🙂
table [Trial_Table]
ID | ProdOrder | ItemCode | MaterialDoc | MvtType | Qty | Unit | Batch | RemQty | ProdLine | Date | ProdLine (groupes) | Qty Corrigé | New Prodline |
150954 | 100005820041 | ZZ70496221-05XM | 6029705832 | 101 | 2400 | PC | 0017964847 | PER | 17/08/2023 06:38 | 50 - PER | 2400 | ||
151079 | 100005820041 | ZZ70496221-05XM | 6029707684 | 101 | 2134 | PC | 0017964847 | PER | 17/08/2023 11:28 | 50 - PER | 2134 | ||
151148 | 100005820041 | ZZ70496221-05XM | 6029708094 | 101 | 2133 | PC | 0017964847 | PER | 17/08/2023 13:43 | 50 - PER | 2133 | ||
151078 | 100005820041 | ZZ70496221-05XM | 6029707682 | 102 | 2400 | PC | 0017964847 | 17/08/2023 11:28 | (Vide) | -2400 | |||
151147 | 100005820041 | ZZ70496221-05XM | 6029708092 | 102 | 2134 | PC | 0017964847 | 17/08/2023 13:42 | (Vide) | -2134 | |||
150716 | 100005820042 | ZZ70496221-05XM | 6029703776 | 101 | 2146 | PC | 0017964849 | PER | 17/08/2023 00:18 | 50 - PER | 2146 | ||
151216 | 100005820043 | ZZ70496221-05XM | 6029708611 | 101 | 2284 | PC | 0017964850 | PER | 17/08/2023 16:43 | 50 - PER | 2284 | ||
151219 | 100005820043 | ZZ70496221-05XM | 6029708626 | 101 | 2283 | PC | 0017964850 | PER | 17/08/2023 16:48 | 50 - PER | 2283 | ||
151217 | 100005820043 | ZZ70496221-05XM | 6029708622 | 102 | 2284 | PC | 0017964850 | 17/08/2023 16:48 | (Vide) | -2284 | |||
150992 | 100005820044 | ZZ70496221-05XM | 6029706124 | 101 | 2222 | PC | 0017964851 | PER | 17/08/2023 07:18 | 50 - PER | 2222 | ||
151456 | 100005820047 | ZZ70496221-05XM | 6029709342 | 101 | 2214 | PC | 0017964854 | PER | 17/08/2023 23:24 | 50 - PER | 2214 |
Hi @What3lse,
If I correctly understand the logic for filling missing values, you could use a calculated column like this:
In plain text for convenience:
ProdLine Updated =
IF ( NOT ISBLANK ( [ProdLine] ),
[ProdLine],
VAR CurrentProdOrder = [ProdOrder]
VAR Result = MAXX ( FILTER ( Data, [ProdOrder] = CurrentProdOrder ), [ProdLine] )
RETURN Result )
Best Regards,
Alexander
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
23 | |
15 | |
12 | |
9 | |
8 |
User | Count |
---|---|
41 | |
32 | |
29 | |
12 | |
12 |