Supplies are limited. Contact info@espc.tech right away to save your spot before the conference sells out.
Get your discountScore big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount
Hi guys
I would ask you about how can I compare values from table to measure .
Please provide your sample file and not screenshots. At least the data (input) and the expected ouput.
Otherwise after reading what you provided I am assuming the following :
The DAX code you provided calculates an `END_DATE_ESP` and compares it with another column to produce a value for `Colonne`.
END_DATE_ESP Calculation
- First, it extracts the `version` column from the `Table_param_version` and the `Année` column from `Year_param` into two separate temporary variables.
- It concatenates the values extracted into two strings `_str` and `_str2`.
- Then it forms a date based on some conditions and extracts the year from that date.
Colonne Calculation
- It compares the `END_DATE` from the `ESP_FAIT_INTRPL_POLCR` table with the previously calculated `END_DATE_ESP`. If `END_DATE` is less, it returns the `NOM_AGENC` value, otherwise it returns blank.
If the `Colonne` column is returning null:
Issue with END_DATE_ESP: The `END_DATE_ESP` might not be getting calculated properly, which can happen if any of the referenced columns like `Day_selected1`, `Mois_selected1`..., have null values or if the `SWITCH` statement doesn't match any value and defaults to returning blank.
Ensure that `ESP_FAIT_INTRPL_POLCR` has values in `END_DATE` and `NOM_AGENC`.
The comparison might be failing due to a data type mismatch or due to some conditions not being met.
Try to :
1. Check if `END_DATE_ESP` returns a valid value on its own without using it in the next calculation.
2. Ensure the `ESP_FAIT_INTRPL_POLCR` table's `END_DATE` has the correct data type and it has valid values.
3. Check the data types of `END_DATE_ESP` and `ESP_FAIT_INTRPL_POLCR[END_DATE]` to ensure they are comparable.
4. Try the `Colonne` calculation without the `if` condition to see if it can pull the `NOM_AGENC` value correctly.
hello ahmed
datevalue(SWITCH(_str, "Actualisé",concatenate(concatenate(concatenate(CONCATENATE([Day_selected1],"/"),[Mois_selected1]),"/"),_str2+1),"Provisoire",concatenate(concatenate(concatenate(CONCATENATE([Day_selected1],"/"),[Mois_selected1]),"/"),_str2)))
yes It contains datevalue but It does'nt word.
may be because I compare column with measure ?
Can you please share your demo input and expected output!
Hello guys
My input is :
I would compare column in my fact table with this mesure :
how can I compare Mesure with column
thank you
pls try this
--- if(ESP_FAIT_INTRPL_POLCR[END_DATE]< DATEVALUE([END_DATE_ESP]) , ESP_FAIT_INTRPL_POLCR[NOM_AGENC] , BLANK())