Distinct values in BI Publisher RTF
template.
Here I got one requirement to calculate
distinct count of Purchase requisition numbers.
Report will display PR number and other
information as shown in below screen shot. Here some PRs having multiple lines.
In report we need to display PRs with
multiple lines and in header we need to display distinct count of PRs.
In above screen shot count is 413 and this is not distinct count.
Because in RTF template I used XML tag in
header level as <?count(field_name)?>
I tried with distinct keyword.
RTF template will not support DISTINCT
keyword.
But publisher having one key word to
calculate distinct values.
i.e :
distinct_values
syntax :
<?count(xdoxslt:distinct_values(field_name))?>
So just I replaced this tag in header level
of RTF template as shown in below screen shot.
<?count(xdoxslt:distinct_values(REQ_NUMBER))?>
And save the template and upload sample data to check
the results.
Now count will be distinct count.
IF report output is blank i.e if no rows in group then the function errors out.
ReplyDelete