How to set filters / parameters through URL

Highly recommend first watching the intro to parameters training video. That will provide the necessary background for the below article.

Syntax

Filters / parameters can be set via URL using the parameter syntax that is appended to the embed URL (note this only works for explicit scope filters/visuals):

http://…/arc/apps/app/9 ?param.parametername=value

There are 3 types of filters, each of which requires slightly different setup.


Example

Let’s say I have a custom filter (output parameter as report_status) with two possible values – Red or Green.

We can set the default value / pre-selected filter by using the following URL:
…/arc/apps/app/10546?param.report_status=Green

image

1 Like

@shaun, can we pass corresponding row value through visual url. In below screenshot I have multiple values under subjectid and I have different visual url for each scenario. when I click on first url then it should goes to the url1 visual along with corresponding row subjectid value.

I was trying with below case statement under url field, but somehow it does work. Can explain what is the wrong I am doing.

URL field expression
CASE
WHEN [scenario] =‘RB-13’ THEN ‘https://xxxxxxxx.nam.nsroot.net:38888/arc/apps/builder/2166?param.subjectid=[subjectid]
WHEN [scenario] =‘RB-10’ THEN ‘https://xxxxxxxx.nam.nsroot.net:38888/arc/apps/builder/2175?param.subjectid1=[subjectid]
ELSE ‘https://xxxxxxxxx.nam.nsroot.net:38888/arc/apps/builder/2160?param.subjectid=[subjectid]’ END as ‘URL’

@Ganesh good question.

You need to use the string function concat() to merge the static base URL with the column value.

I would modify the calculation expression to look like this:

WHEN [scenario] ='RB-13' THEN concat('https://xxxxxxxx.nam.nsroot.net:38888/arc/apps/builder/2166?param.subjectid=',[subjectid])
WHEN [scenario] ='RB-10' THEN concat('https://xxxxxxxx.nam.nsroot.net:38888/arc/apps/builder/2175?param.subjectid1=',[subjectid])
ELSE concat('https://xxxxxxxxx.nam.nsroot.net:38888/arc/apps/builder/2160?param.subjectid=',[subjectid]) 
END as 'URL'
2 Likes

Thank you again, I was trying the same before I posted the query but any how it worked now. This would help us to navigate multiple dashboards from summary.

:man_dancing:

1 Like

Hi Shaun,

It works great, is it possible to use a link generated this way behind an image, so it works like some kind of button

thanks again for your help!!

@Carlos_Bocanegra you can use any arbitrary HTML in the table field, for example this would produce a button link:

'<a href="https://google.com" class="btn btn-info" role="button">Link Button</a>' as 'link'


Note - make sure to enable HTML in the settings

1 Like

This is great!! is it possible to mix both solutions so using the dynamic links to point to dashboard filtered based on parameters in the URL and this kind of visualization?

I don’t see why not.