From dataiku API how to access to SQL Probe code
oscieux
Registered Posts: 3 ✭✭✭
Hi all,
My question is in the subject
Do anyone have a solution please?
Tagged:
Best Answer
-
Alexandru Dataiker, Dataiku DSS Core Designer, Dataiku DSS ML Practitioner, Dataiku DSS Adv Designer, Registered Posts: 1,237 Dataiker
Hi @oscieux
,You can use the get_dataset() get_settings() get_raw() to retrieve SQL Probe code:
import dataiku import pprint pp = pprint.PrettyPrinter(indent=4) client = dataiku.api_client() project = client.get_default_project() dataset = project.get_dataset("IMPORT_FROM_V5_sql_bad") settings = dataset.get_settings() params = settings.get_raw()['metrics']['probes'] for i in params: if i['type'] == 'sql_query': pp.pprint(i['configuration']['code'])
Let me know if that's what you were looking for!
Answers
-
U are the best
Thxs a lot !