How to pass a variable obtained from query compone

2019-08-24 18:20发布

I managed to get data as variable with Query component. Now I want to pass this variable into a query. Here is what I did:

On Query Component: myresult='NYC' in my example.

enter image description here

The query on Datasources: I use this one to display a chart, when I change ${myresult} to 'NYC', it works fine. But with ${myresult}, the chart is not displayed.

enter image description here

I also tried with

> Dashboard.setParameter() 

On post fetch of Query Component, but still the same...

enter image description here

I also created simple param and select param (which is not displayed on dashboard) but it doesn't solve the problem.

It's been hours I'm stuck , would love to get some help!

///////////////////////////////EDITED/////////////////////////////

On Component Panel - simple parameter :

enter image description here

On Component Panel - Pie chart - Parameters :

enter image description here

On Component Panel - Pie chart - listeners : I selected param_city

On Datasource - parameters of piechart query:

enter image description here

1条回答
兄弟一词,经得起流年.
2楼-- · 2019-08-24 18:52

you need to pass parameter myresult and listner in Parameters field of both chart and datasource used for chart. like this

查看更多
登录 后发表回答