sql server - Conditionally count based on other field data in SSRS Report -
i working ssrs report, have field named details , count of other field serialnumber.
so in short want total count of serialnumber has no details.
i tried below not working. give total count count without considering blank details
=cstr(count(iif(not(isnothing(fields!details.value)),fields!serialnumber.value,0))) how can achieve expression? please help.
issue data. in dataset fetching rows based on isnull() below
select case when 'y'='y' isnull(code ,'') + ' ' + isnull(description ,'') else case when isnull(code ,'')='' isnull(refcharge ,'') +' '+isnull(refdescription ,'') else isnull(code ,'')+' '+isnull(description ,'') end end details so showing (3 blank spaces) , expression was.
=count(iif(fields!details.value<>"",fields!number.value,nothing)) finally tried below, it's working fine now.
=count(iif(trim(fields!details.value)<>"",fields!number.value,nothing)) note: so have noted whenever need check such kind of conditions must have use trim()
Comments
Post a Comment