4

Presently within Azure Datafactory V2, the default null value for flat file output is set as "\N", which causes the downstream processes to fail as datafactroy is creating flat files with a float, int or decimal value set to "\N".

Within the advanced features of the datafactory datasets, we can set the null value to a certain character:

enter image description here

What value can I set this to so as to permit simply an empty space instead of a " ", blank space or other character that would cause issues?

Sauron
  • 6,399
  • 14
  • 71
  • 136
  • 1
    This causes problems parsing templates as well, particularly in PowerShell. :( – Johns-305 Aug 24 '18 at 14:02
  • @Johns-305 Well, already found a work around. I am using the string function @concat() and a blank string as two single quotes: '', (not one double quote), so using @concat('') as the Null value override in the "Add Dynamic Content" when hovering over the input box. – Sauron Aug 24 '18 at 14:08

1 Answers1

1

Just remove \N and leave that input box empty will achieve this.

You could also click the code button (right top conner of the following screen shot) in the UI to see the json payload of the dataset.

enter image description here

Fang Liu
  • 2,325
  • 2
  • 13
  • 18
  • Presently the box is empty. The default, behind the scenes override is to set null values to \N no matter what. So there needs to be an override else ADFv2 will set to \N – Sauron Aug 24 '18 at 14:39
  • If you didn’t set the nullValue in json, the behind scenario will write null value as \N. – Fang Liu Aug 24 '18 at 15:00
  • But in UI, if you remove \N, the json payload is actually “nullValue”:“”. So behind won’t take default value. Instead, “” will be used. That is exactly the same as concat(“”,””). Just more simple. – Fang Liu Aug 24 '18 at 15:02
  • This is datafactory V2, there is no JSON. I have solved the problem, this is closed. – Sauron Aug 24 '18 at 15:42
  • 1
    I know this is v2. If you open a dataset tab, there is a code button at top right conner, click it, you will see json. – Fang Liu Aug 24 '18 at 23:05
  • Just leaving the box empty caused it to use the default value of "\N" for me, but opening the JSON view and actually entering `"nullValue":""` worked to get a truly blank value for nulls without needing to have an expression that returns a blank value. – DavidP Sep 25 '18 at 11:50