cancel
Showing results for 
Search instead for 
Did you mean: 

file with various field lengths non - fixed cardinalities problem

Former Member
0 Kudos

Hallo all,

we have the following problem.

we implemented a scenario as sown in this blog

/people/venkat.donela/blog/2005/06/08/how-to-send-a-flat-file-with-various-field-lengths-and-variable-substructures-to-xi-30

but there is a problem.

If the file structure is declared as :

Header,1,Items,*

then the adapter does not even read the file from the directory (so I assume that for some reason the file structure is not as expected).

If on the other had the structured is declared as :

Header,1,Items,3

everything works.

Obviously though, this is not satisfying since we need variable cardinalities.

Any suggestions and help is appreciated

Thank you .

Accepted Solutions (0)

Answers (8)

Answers (8)

Former Member
0 Kudos

Thank you all very much, the question was finally answered here :

https://www.sdn.sap.com/irj/sdn/forums

Former Member
0 Kudos

anyone?

could it be a service pack issue ?

Former Member
0 Kudos

I should probably mention that it also works with multiple records, as long as i have fixed cardinality for the items

Former Member
0 Kudos

Yes, there is a rroot element, although probably not needed.

Yet we have also used the ignoreRecordsetName=true directive because I don't want it to show in the produced structure

Former Member
0 Kudos

Well, I will write the main tests we tried, in case that the situation could be cleared :

I have a specific file in a standard directory, called xi_input. The file is edited straight into that directory, so there can't be filename errors etc.

If the file is left empty :

Nothing happens . No message of any kind in sxmb_moni/monitoring xml messages .

If the file contains the following (data is random) , where 'H' is the key for the header and 'I' is the key for the items :

H 20060403 16 3 316001 kapou lalla morellala 20060403 F3 23

I 277101010 2

I 277101011 3

I 277101012 4

There are to cases :

if the file structure is declared as :

Header,1,Items,*

Then nothing happens .

If on the other had the structured is declared as :

Header,1,Items,3

everything works .

I guess there is now a more clear picture of the problem.

As for whether the file adapter does care about the file contents or not, I think that if the Message Protocol is "Message Content Conversion", then it does check the structure.

former_member194786
Active Contributor
0 Kudos

Hi Markos,

Did you create a root node for the document? In the blog they have taken the header field under the Root node.

Regards,

Sanjeev.

Former Member
0 Kudos

Hi,

then the adapter does not even read the file from the directory (so I assume that for some reason the file structure is not as expected).

File adapter is unable to perform field level validations. it will perform only file level validations.

Like name of the file and source Path of the file.

Field level validations are performed on message mappings.

Header, 1, Items, *

And the structure u declare is correct.

Please check your file name and source path when u gave that structure.

Note: u can check without giving any data in your file with the same name and path that specify in sender file adapter.

Regards,

Pradeep A.

Former Member
0 Kudos

wats the occuurrence for Items node

Former Member
0 Kudos

Hi, I guess you mean this :

Header :

keyfield,CreationDate,CentralCustomerCode,CustomerCode,ReferenceDocumentNumber,DeliveryPlace,Message,ReturnMessage,DeliveryDate,SalesmanCode,Rest

Items :

keyfield,Material,Quantity

former_member194786
Active Contributor
0 Kudos

Hi Markos,

What is your source structure????

Regards,

Sanjeev.