How can I retrieve the list of foreign datasets used in my Dataiku project?

ELACHAR
ELACHAR Registered Posts: 4 ✭✭

How can I retrieve the list of foreign datasets used in my Dataiku project that originate from other projects?

Answers

  • Han_Han
    Han_Han Dataiker, Registered Posts: 29 Dataiker
    edited October 14

    Hi @ELACHAR,

    I checked quickly and I am not sure there is an easy to do that.

    Do you know why do you want to do that? Why do you need this? What problem are you trying to solve with this? Happy to help working on a feature request too.

    Han (email: han.han@dataiku.com)

  • Turribeach
    Turribeach Dataiku DSS Core Designer, Neuron, Dataiku DSS Adv Designer, Registered, Neuron 2023, Circle Member Posts: 2,598 Neuron

    Something like this should do it:

    import dataiku
    client = dataiku.api_client()
    project = client.get_project("CT_TEST")
    for shared_object in project.get_settings().get_raw()["exposedObjects"]["objects"]:
        print("Object id=%s type=%s is shared to project:" % (shared_object["localName"], shared_object["type"]))
        for rule in shared_object["rules"]:
            print("%s" % rule["targetProject"])
    
Setup Info
    Tags
      Help me…