on 05-20-2008 4:03 PM
Hi,
I'm working on PI 7.0.
I send a file to the adapter like this:
123~4
567~8
i have the following parameters
nameA.fieldSeparator: ~
nameA.fieldNames: text1,text2,text3,text4
nameA.endSeparator: nl
ignoreRecordsetName: true
If i leave out the endSeparator the xml message in the integration looks exactly the same.
Question:
what parameters should i use to properly use endSeparator? (say for instance i want to use # as endSeparator)?
Should i change the fieldnames string?
I'm asking because the file might have empty fields and it comes in the integration engine wrong if the last field is empty.
Please help.
Hi,
You can use any thing as you want
if endSeparator = newline, then
nameA.endSeparator = 'nl'
nameA.fieldSeparator =~
nameA.fieldNames = field1,field2,field3,field4
if endSeparator = #, then
nameA.endSeparator = #
nameA.fieldSeparator =~
nameA.fieldNames = field1,field2,field3,field4
No need to change the fieldnames.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
I know i can use anything string as endSeparator. Say i use #.
Now my file was like
123~4
Using the end separator # it will look like
123~4#
Correct?
Whatever setting i tried sofar the #-sign always ends up in the XML, i.e 4#
What i want to happen is that the system recognizes the # as end of line and gives me a 4 in the message, instead of 4#.
Hi Venkataramesh,
What you describe is what should be happening and what i expected, based on the help file from SAP.
What really happens though is that the # sign ends up in the XML.
The problem i have is that if i start leaving fields out form the file i send in
(i might send 1~3 instead of 123~4) the XML message in the integration engine is missing a tag.
The last one to be precise.
Hi Gabriel,
This also happens if I use the solution that you propose (using the fromConfiguration)
So i'm afraid my problem is still not solved.
Check these two parameters.
Use the following parameters if you want to influence the behavior of the conversion routine for inbound structures that deviate from the configuration.
1. NameA.missingLastfields
If the inbound structure has less fields than specified in the configuration then the XML outbound structure is created as follows:
○ ignore
Outbound structure only contains the fields in the inbound structure
○ add
Outbound structure contains all fields from the configuration; the fields missing in the inbound structure are empty.
○ error
Conversion is terminated due to the incomplete inbound structure. An error message is displayed.
2. NameA.additionalLastFields
If the inbound structure has more fields than specified in the configuration then the XML outbound structure is created as follows:
○ ignore
Outbound structure only contains the fields in the inbound structure
○ error
Conversion is terminated due to the incomplete inbound structure. An error message is displayed.
The default value is ignore. If you have defined the NameA.fieldFixedLengths parameter, the default value is error.
If you have defined the NameA.fieldFixedLengths parameter and do not set either of the parameters described above, apart from the default values, the conversion routine works the same as described under Handling Structure Deviations.
Only once you set one of the two parameters will the other parameter be evaluated with its default value.
To ensure a well-defined runtime behavior for variable inbound structures, we recommend that you always set both parameters.
Hi Deepthi,
Thx, but again it does not work as you say, and as SAP says in the helpfile.
I'll ask the admin guy if maybe there is something msising form the installation or something.
And i'll also try this out on a different system, but that might take a while to implement.
Unless anybody else has a new approach i will not spend much more time on this in the next week or so.
Thx all for trying to help.
nameA.fieldSeparator =~
nameA.endSeparator ='nl'
nameA.fieldNames =text1,text2,text3,text4
nameA.processFieldNames fromConfiguration
nameA.lastFieldsOptional Yes
nameA.missingLastFields Add
nameA.additionalLastFields ignore
ignoreRecordsetName: true
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
81 | |
9 | |
9 | |
7 | |
7 | |
6 | |
6 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.