I am trying to create generate CSV file of a dashboard using the SDK. I seems that Looker only provide the rendered task to generate dashboard to PNG.
So, I'd like to get the query_id of each tiles based on the dashboard_id. Then I noticed that if I change the dashboard filter and updated the dashboard, will the query_id of the dashboard get updated or just use the same query_id but with the latest information with the updated filter value?
The easiest thing to do would be to take the query definition and modify it to your liking with the proper filter, then run the "run_inline_query" api endpoint.
https://developers.looker.com/api/explorer/4.0/methods/Query/run_inline_query
Hi, thank you for your response. I will explain a little bit more about my workflow. The dashboard filter will be updated by the user from the Looker instance/UI. Then when the user changes the filter and clicks the updated button, I'm thinking about retriving the query_id with the updated filters and values.
Hi @fajaribnuf - There is a way to get a URL from Looker that can be used to download the Look's data in csv format. Please follow below steps
1. Go the the specific Look > click the gear on right top > select "Edit Setting" option
2. From the URL section, copy the full part and paste in a notepad, in the URL delete every thing after the '?' , including '?'.
3 The remaining URL will end with '.txt', change it to '.csv' and test the URL in a new tab of browser.
4. For me it worked and downloaded a csv file with data of that particular Look.
Hope this helps
~Ashish
That is a good trick. It requires that the cookies be set for a currently logged in session. It might work perfectly for the original poster's use case, but it might also be hard if the user needs to automate a workflow.
I tried the URL of a public Look in an incognito window and it worked fine. I believe cookies are not required for accessing public Looks externally.