Skip to content

Instantly share code, notes, and snippets.

@joshlk
Last active September 13, 2018 11:33
Show Gist options
  • Save joshlk/d6550ab29d672a6eb310a2e722b69581 to your computer and use it in GitHub Desktop.
Save joshlk/d6550ab29d672a6eb310a2e722b69581 to your computer and use it in GitHub Desktop.
Dataiku DDS Public API examples
import dataiku
import dataikuapi
from dataikuapi import SQLQueryRecipeCreator
### Creare SQL recipy
builder = SQLQueryRecipeCreator('compute_output', project)
builder.with_input('input')
builder.with_new_output('output', 'connection')
recipe = builder.build()
sql = """
SELECT * FROM ...
"""
recipe_def = recipe.get_definition_and_payload()
recipe_def.set_payload(sql)
recipe.set_definition_and_payload(recipe_def)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment