cancel
Showing results for 
Search instead for 
Did you mean: 

default value mapping

Former Member
0 Kudos

Hi all

If my receiver side field occurence is 0-1, but i want it always to be mapped with some value say "1" even if input field is not occuring , and the input side suppress will not be there,so we can not use map with default also,is there some way to map a default value say in receiver file content conversion?

Thanks

Pratichi

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Just use a if condition to check if input field is not empty then only pass it to target else pass the constant. This will solve the problem.

Edited by: Sarvesh Singh on Nov 24, 2009 6:32 PM

Former Member
0 Kudos

input field is neither suppress not is it blank.

Input field is under another node. and output field is not mapped with this node but another node

Former Member
0 Kudos

Hi,

for your source node value, how many times you have it ?

If it's only one, maybe you can stored this info into a Global variable, and then use your global variable for your Value Mapping.

Very strange your story...

Regards.

Mickael

Former Member
0 Kudos

Input field is under another node

Then use function useOneAsMany and mapWithDefault for generated nodes.

Kind regards,

Radek

Answers (3)

Answers (3)

sunil_singh13
Active Contributor
0 Kudos

Hi Pratichi,

You can use "if-else", you have to check if value exist or value is not empty then pass the source field value else you can pass the constant value say "1".

Thanks,

Sunil Singh

former_member187339
Active Contributor
0 Kudos

Hi Pratichi,

Not in file content conversion you can achieve this in message mapping using:

1. mapwithdefault or

2. fixmappings

3.valuemappin

etc..

Regards

Suraj

Former Member
0 Kudos

Have you tried to use Constant value with if statement in your mapping? It might solve mapWithDefault problem.

Kind regards,

Radek