Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Experts,
Can any one please help me to convert below oracle decode function into Qlik UI as expression.
round( Sum ( decode ( [name] , 'valuerisk', [Value] ,0 ) ) /1000, 2 )
Here name and Value are the fields.
jontydkpicould you please help me.
Thnaks in advance.
Hi Mahitha,
=round(sum(if(WildMatch([name],'valuerisk'),[value],0))/1000,2)
use this expression and tel me what answer are you getting
Hi,
Try this and see,
=round(sum(if(WildMatch([name],'valuerisk'),'1', if(WildMatch([value],'0'),'2','9' )))/2,2)
Regards,
keerthika
Hi Keerhtika,
Thanks for your reply.
I did not understand which you have mentioned ,'2','9' could you please explain once.
Hi,
In oracle decode function syntax is
decode(column name,'100','IBM',
'200','Microsoft',
'others')
if the column name is 100 it display IBM, if it is 200 it display Microsoft otherwise 'others'
Like that
=round(sum(if(WildMatch([name],'valuerisk'),'1', if(WildMatch([value],'0'),'2','9' )))/2,2)
in the above expression if [name] is 'valuerisk' it will display 1 , if value is 0 it will display 2 otherwise 9.
Is this way you are expecting?
Hi Keerthika,
I am new to oracle.
My output value is like -42.88 for one of the record but by the above expression I am getting 45.00.
I have used below one.
=round(sum(if(WildMatch([name],'valuerisk'),'1', if(WildMatch([value],'0'),'2','9' )))/2,0.01)
When I have selected value = 0 in the table this expression is showing 1.00 not 2 as per your expression.
Hi Mahitha,
=round(sum(if(WildMatch([name],'valuerisk'),[value],0))/1000,2)
use this expression and tel me what answer are you getting