0
votes

I am trying to understand apache nifi in and out keeping files in hdfs and have various scenarios to work on. Please let me know the feasibility of each with explanations. I am adding few understanding with each scenario.

  1. Can we check null value present with in a single column? I have checked different processors, and found notNull property, but I think this works on file names, not on columns present within file.
  2. Can we drop a column present in hdfs using nifi transformations?
  3. Can we change column values as in replace one text with other? I have checked replaceText property for the same.
  4. Can we delete a row from file system?

Please suggest the possibilities and how to achieve the goal.

1
Hi @Garima and welcome to Stackoverflow! Questions on Stackoverflow work best, if they are very specific. You might get better answers, if you to find your own solutions and ask for help, as soon as you are stuck. - slartidan

1 Answers

0
votes

Try with this:

1.Can we check null value present with in a single column? I have checked different : Yes using replace text processor you can check and replace if you want to replace or use 'Route on Attribute' if want to route based on null value condition.

  1. Can we drop a column present in hdfs using nifi transformations? Yes using same 'ReplaceText' processor you can put desired fields with delimiter as I used to have current date field and some mandatory fields only in my data with comma separated so I provided replacement value as

"${'userID'}","${'appID'}","${sitename}","${now():format("yyyy-MM-dd")}"

  1. To change column value use 'ReplaceText' processor.