cancel
Showing results for 
Search instead for 
Did you mean: 

Assign a default value to column in flowgraph

PallaviU
Participant
0 Kudos

Hi,

I need to assign a default value to a column in the flowgraph.I used map operation transform to assign the value in the mapping tab as shown below.

when I try to execute the flowgraph it throws an error as shown below.

Could you please suggest to resolve the issue?

Thanks

Pallavi

Accepted Solutions (1)

Accepted Solutions (1)

PallaviU
Participant
0 Kudos

Hi Jeff,

I have removed the if condition and the error is resolved. However I have added the addtional column and assigned default value in the filter.

Thanks

Pallavi

Answers (1)

Answers (1)

jeffrey_kresse
Employee
Employee

Hi Pallavi,

I think you probably want to use the HANA IFNULL() function. The function returns the first non-null value in its list, so put the mapped column first, and have a default value follow it in the list. Your mapping should look something like this:

IFNULL("INPUT"."FILE_TYPE", "E")

You said there is some kind of error, but I don't see any error message in the post. Can you share the error text?

Thanks,
Jeff K

PallaviU
Participant
0 Kudos

Hi Jeff,

Thanks for your quick response. I have tried with the option mentioned but encountered with the same error. May be the error is in any other part of flowgraph I am not sure. Please find the error snapshot and suggest to proceed further.

error.jpg

Thanks

Pallavi

jeffrey_kresse
Employee
Employee
0 Kudos

The error comes from an ELSE somewhere in the design of the flowgraph. I don't see any ELSE in your first screenshot so it must be another mapping.