Replace Extract in Packaged Workbook

Aperta
#102 4 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
25/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
python
Ambito
tooling

Direzione di ricerca

Start with tableaudocumentapi.Workbook and its save_as method, then compare the existing .twb XML reference replacement with the packaging behavior of .twbx files. Investigate how the connection's .tde extract is represented in a packaged workbook. Done means replacing the extract while preserving the table definition and producing a self-contained new_workbook.twbx.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

enhancement

I'm trying to figure out how to replace an extract in a packaged workbook with a different extract that has the same table definition. I can use the Tableau SDK to create a new .tde, but it looks like there aren't python methods to replace an extract in a packaged workbook.

I'm imagining this would look something like this:

from tableaudocumentapi import Workbook

sourceWB = Workbook('workbook.twbx')
sourceWB.datasources[0].connections[0].extract = "MY-NEW-EXTRACT.tde"
#OR sourceWB.datasources[0].connections[0].extract.package('new-extract.tde')

sourceWB.save_as('new_workbook.twbx')

I can replace an extract in a .twb file by hacking the xml and changing references, but the "save_as" method doesn't actually package the workbook so that the connection is no longer dependent on a .tde file.

Lingua principale
Python
Stelle
363
Fork
183
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di tableau/document-api-python

Tutte le issue di tableau/document-api-python

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.