Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a straight table. I want the table to display metrics only for values that do not have an expiration date. Can I do that with a calculated dimension. I tried =if([Expiration date] ='-', [Expiration date]) and hide the column. Its not working. pls advise.
Try this expression:
=Sum({<[Expiration date] = e([Expiration date] = {'*?'})>} Cost)
I think this should work.
Best,
Sunny
You do not need extra dimension
only({1-<ExpirationDate={*}>} Cost)
or without Expiration date dimension:
here is another alternative
Sum({$<ProductID={"=nullcount(ExpirationDate)>0"}>} Cost )
this is based out of HIC document
Sum(If(IsNull(ExpryDt), Cost))
Or
Sum({<ProdID={'=IsNull(ExpryDt)'}>}Cost)
Robert, the function I am using is not sum in my app. It is a filter that I have created in the script. However the logic remains the same. as of now My expression is
=count({<[extra inventory]={1}>} Distinct [TRANS_ID]) Where [extra inventory] is the condition I created in the script. and I have a straight table thats pulling records that satisfies the condition. but it is also pulling all values in expiration date field. how do I show only those that do not have an expiration date. I tried : =count({<[extra inventory]={1}, [expiration date]={'*'}>} Distinct [TRANS_ID]) and it brought those records that had expiration dates. how do I achieve the opposite of it, i.e. records that do not have an expiration date. I am hoping for a fix on the front end. either a set anlaysis expression combined with my main expression above or a calculated dimension for the [expiration date]. Thanks much
count({$<ProductID={"=nullcount([expiration date])=0"}, [extra inventory] = {1}>} distinct [TRANS_ID])
or on your current expression change it to [expiration date] -= {'*'}
=count({<[extra inventory]={1}>} Distinct If(IsNull([expiration date]),[TRANS_ID]))