Hey, I have been trying to create a new column in my table using an IF statement, but when I try to reference a column in my date table, it only shows autofill for measures in that table and not columns. When I try typing in the column name Date, It says it cannot find it. When I try to create the calculated column anyways, it gives me this error: A single value for column 'Date' in table 'Calander' cannot be determined. This can happen when a measure formula refers to a column that contains many values without specifying an aggregation such as min, max, count, or sum to get a single result. I have made sure I am not creating a measure, I have never had this problem before. I attached a screenshot of what my date table looks like too. Any help?
Solved! Go to Solution.
Hi @Anonymous ,
Try selectedvalue funtion as below.
IF (SelectedValue(TableName[ColumnName]) = "Condition")
Thank you.
Hi @Anonymous ,
Try selectedvalue funtion as below.
IF (SelectedValue(TableName[ColumnName]) = "Condition")
Thank you.
What does selected value mean for this?
I'm guessing you're trying to create a new calculated column in a table other than 'Calander'? In this case, the error is exactly as described. It doesn't know which Date value you're trying to reference (since there isn't any row context).
What is your IF column attempting to do?
@Anonymous , There might be another date column in the model, better to use 'Date'[Date].
The measure will take measure and aggregated columns
User | Count |
---|---|
129 | |
61 | |
55 | |
54 | |
43 |
User | Count |
---|---|
129 | |
61 | |
57 | |
56 | |
50 |