Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I want to count the order_id where the comment field is empty. (in a straight table)
if anyone could help it would be great
Try like :
=Count ( Distinct If( Len(Trim(comment))=0, order_id))
Hi,
Try like this..
Count({<comment={' '}>} order_id)
This should work:
=Count(DISTINCT order_id) - Count({<comment={"*"}>} DISTINCT order_id)
- Ralf
Thanks for your replies. I still can't get it to work. I probably didnt explain properly:
the expression I have is:
count({$<[KPI within 1] = {'1'}>} distinct order) I now need to have the same expression but only count the comment fileds that are blank or have ' - ' in them?
Thanks
Have you tried the ISNULL function?
If(isnull(Comment),count(order_id),0)
Hi rhona,
Try this on script level
Load Order_id,
if(isNull(Order_id),'NULL','NOT_NULL') as ORDER_ID_NULL_FLAG
from table_name;
then count NULL values on expression level,
=count(<ORDER_ID_NULL_FLAG = {<'NULL'>}> Order_Id)
This will return you the count of only Null Order Id
Thanks and Regards,
Vishal Waghole
HI
Try like this
count({$<[KPI within 1] = {'1'}, comment -={'*'}>} distinct order)
Try load with:
LOAD *,if(comment ='','-',comment) as comment1
from TABLE_NAME;
And then use following expression in chart:
count({$<[KPI within 1] = {'1'}, comment1 = {'-'}>} distinct order)
Hope it helps...