Creating workbooks and data source files
It would be very useful to be able to create a workbook or data source files, not only modify existing ones.
Thanks, @henridwyer! Creation is definitely on our radar. Do you have any suggested starting points? How would you want to create something? Totally from scratch? Would love any more info you could provide about how you'd like to use it.
It would be nice to create a TDS for any arbitrary connection, something like:
connection = Connection.create(dbname, server, username, authentication)
Datasource.create(output_file_name, connections=[connection]).save()
OK cool thanks for the additional feedback.
From: Henri Dwyer [email protected] Reply-To: tableau/document-api-python [email protected] Date: Thursday, July 28, 2016 at 14:41 To: tableau/document-api-python [email protected] Cc: Ben Lower [email protected], Comment [email protected] Subject: Re: [tableau/document-api-python] Creating workbooks and data source files (#68)
It would be nice to create a TDS for any arbitrary connection, something like:
connection = Connection.create(dbname, server, username, authentication) Datasource.create(output_file_name, connections=[connection]).save() — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.
Creating a connection (with the subset of elements we support today) would be pretty simple: Add a new class method that builds an empty Connection ElementTree-tree and then pass that into the existing Constructor and fill out all the attributes.
Making a datasource is a little trickier... Making the skeleton for the XML is easy enough, but we don't have any logic to build out columns and such yet -- I think an empty datasource would still load in Desktop/Server but I'd have to check to see if anything is broken.
I like the api recommended by @henridwyer -- connections=[c1, c2, c3]
Any update on this I am also trying to create empty Workbooks with DataSource in it.