Exporting NULL values as NULL instead of empty for CSV files

MRvLuijpen
MRvLuijpen Partner, L2 Admin, L2 Designer, Dataiku DSS Core Designer, Dataiku DSS & SQL, Dataiku DSS ML Practitioner, Dataiku DSS Core Concepts, Neuron 2020, Neuron, Dataiku DSS Adv Designer, Registered, Dataiku DSS Developer, Neuron 2021, Neuron 2022, Frontrunner 2022 Finalist, Frontrunner 2022 Winner, Frontrunner 2022 Participant, Neuron 2023 Posts: 107 Neuron

Hi Community,

Just a quick question.

Maybe it is a bit of an uncommon request, but I have a table with many NULL values, and when I export it to CSV, this NULL values become empty cells. Is it possible to export the NULL value?

Cause these CSV file is used as input for a tool and it needs to read NULL values and not empty cells.

Thanks in advance.

Marc Robert

Answers

  • VinceDS
    VinceDS Dataiker, Alpha Tester, Dataiku DSS Core Designer Posts: 45 Dataiker

    Hi Marc,

    What you could try is inside of an Analysis (or in a Prepare), mass replace all your empty values by 'NULL' (select 'all' for applicable columns in the processor).

    Screenshot 2021-08-20 at 15.32.41.png

    You can then export the dataset either directly from the Analysis Action tab or from your flow.

    Hope this helps

  • MRvLuijpen
    MRvLuijpen Partner, L2 Admin, L2 Designer, Dataiku DSS Core Designer, Dataiku DSS & SQL, Dataiku DSS ML Practitioner, Dataiku DSS Core Concepts, Neuron 2020, Neuron, Dataiku DSS Adv Designer, Registered, Dataiku DSS Developer, Neuron 2021, Neuron 2022, Frontrunner 2022 Finalist, Frontrunner 2022 Winner, Frontrunner 2022 Participant, Neuron 2023 Posts: 107 Neuron

    Hello Vince (@VinceDS),

    When I try to do this, it will also change the storing type from decimal towards text.

    And that is something that is not really prefered.

    But thank you for your response.

    Best wishes

    Marc Robert

Setup Info
    Tags
      Help me…