Forum Discussion
Calculated Coloumn error
Hi
Anonymous
I am getting the below error
for a calculated coloumn
Hi vjnvinod ,
According to the error message, there can only be one field type in the same column in powerbi desktop. If the Updated ON field is, for example, a number type, then the judgment condition "No Project" is a Text type. It is not possible to create a column of this type.
Change Updated ON to test type, then try the measure like below:
updated ON_1 = IF('Table'[Update On]=BLANK(),"No Project",'Table'[Update On])If the problem is still not resolved, please provide detailed error information and let me know immediately. Looking forward to your reply.
Best Regards,
Henry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
6 Replies
- amitchandakSuper User
vjnvinod , Try like
Updated ON_1 = IF(ISBLANK(GPN[Update On]),"No Project",GPN[Update On] & "" )
seems like GPN[Update On] is not text
- vjnvinodImpactful Individual
this is my calculated column, which is generating the blank, how do I tweak this formula so that Blank can come as "No project" with the below formula
Update On = If(LOOKUPVALUE(Mercury_Extract[last Updated on],Mercury_Extract[Resource GPN],GPN[GPN])<>BLANK(),LOOKUPVALUE(Mercury_Extract[last Updated on],Mercury_Extract[Resource GPN],GPN[GPN]),LOOKUPVALUE('Retain Last Updated'[Retain Last Updated on],'Retain Last Updated'[GUI],GPN[GUI]))- amitchandakSuper User
vjnvinod , Assuming code is correct
Update On =
var _1 = If(LOOKUPVALUE(Mercury_Extract[last Updated on],Mercury_Extract[Resource GPN],GPN[GPN])<>BLANK(),LOOKUPVALUE(Mercury_Extract[last Updated on],Mercury_Extract[Resource GPN],GPN[GPN]),LOOKUPVALUE('Retain Last Updated'[Retain Last Updated on],'Retain Last Updated'[GUI],GPN[GUI]))
return
if(isblank(_1), "No Project", _1)
- v-henryk-mstfCommunity Support
Hi vjnvinod ,
According to the error message, there can only be one field type in the same column in powerbi desktop. If the Updated ON field is, for example, a number type, then the judgment condition "No Project" is a Text type. It is not possible to create a column of this type.
Change Updated ON to test type, then try the measure like below:
updated ON_1 = IF('Table'[Update On]=BLANK(),"No Project",'Table'[Update On])If the problem is still not resolved, please provide detailed error information and let me know immediately. Looking forward to your reply.
Best Regards,
Henry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.