Created
January 30, 2016 15:06
-
-
Save tfoldi/fa15d88b0ef04fcc74e2 to your computer and use it in GitHub Desktop.
Get published data sources with workbooks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select * | |
from datasources | |
inner join data_connections on (data_connections.name = datasources.name) | |
inner join workbooks on (data_connections.owner_id = workbooks.id) | |
where data_connections.dbclass = 'sqlproxy'; |
This query will return a more reliable match as there could be more than datasource with the same name on your server
select w.id as workbook_id, w.name as workbook_name, d.id as datasource_id, d.name as datasource_name from data_connections dc join workbooks w on dc.owner_id=w.id join datasources d on w.id=d.parent_workbook_id where dc.caption = 'Sample - Superstore' and dc.dbclass = 'sqlproxy' ;
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi Tamás, thank you. For some reason, this SQL isn’t working for me.
From my v9.0.5 postgres, I get:
ERROR: column reference "asset_key_id" is ambiguous; Error while executing the query
Also, when I try to build the same join conditions using the visual data connection window in Tableau, I find that some of the published data sources have a DBCLASS = 'teradata' (not 'sqlproxy').
Thoughts ?
Thanks!
Keith Helfrich | Twitter
Red Headed Step Data