Skip to main content
Hi, is there a way we can use the python API to find and replace field names specified in PQL within an analysis?
For example, Im linking an existing analysis to a new data model and some of the field names differ slightly e.g. BSEG.TS_AUGDT is now BSEG.AUGDT. Is there a way I can easily update the PQL to use the new fieldname definition via the API without having to update manually via the front end?

Hi Nabaa,

 

One way might be to use functions like create_backup and restore_from_backup, this could be a potential method:

  1. Download analysis backup within MLW using create_backup
  2. Print and explore the analysis object, and rename fields within python if they are accessible
  3. Push back the analysis with the restore_from_backup function.

 

For reference the full Pycelonis documentation is here: https://celonis.github.io/pycelonis/index.html

 

Best,


Reply