cancel
Showing results for 
Search instead for 
Did you mean: 

mandatory /option fields

Former Member
0 Kudos

Hello

I am doing soap to proxy scenario sync.

some fields in soap are optional and some are mandatory, when we define option fields in data types ? can the xml tags also be optional or is it just the values within that particular tag which is optional? Thanks

Accepted Solutions (1)

Accepted Solutions (1)

stefan_grube
Active Contributor
0 Kudos

> can the xml tags also be optional or is it just the values within that particular tag which is optional?

It is just the other way round: If a field is mandantory, it means that the tags are mandantory. The XML values are always optional, unless they are described more detailled.

But you always need to know, which fields have to be filled to make the XML semantically complete. You cannot omit fields just because they are optional.

Former Member
0 Kudos

1) I made the field optional in PI 7.1 by changing min occurrence to 0. Is this the correct way or we can explicitly set a particular field as required or optional?

2) Secondly if a field is optional , so the xml tag need not be present or the value can be optional but tag has to be present always ?

Thanks

stefan_grube
Active Contributor
0 Kudos

> 1) I made the field optional in PI 7.1 by changing min occurrence to 0. Is this the correct way

yes

> 2) Secondly if a field is optional , so the xml tag need not be present or the value can be optional but tag has to be present always ?

The XML tag need not be present.

Answers (2)

Answers (2)

prateek
Active Contributor
0 Kudos

When there are no values in the fields, usually the tags doesn't come at all in PI. Anyway, the sender side datatype is not validated when the message reaches PI.

Regards,

Prateek

Shabarish_Nair
Active Contributor
0 Kudos

you can set mandatory or optional by changing the occurrence of a field or segment. note it is modifiable at both field and segment level