cancel
Showing results for 
Search instead for 
Did you mean: 

File-Adapter J2SE

Former Member
0 Kudos

How can i get the XSLT code from xi, it is possible?

Thanks

Yves

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

>>How can i get the XSLT code from xi, it is possible?

what exactly are you looking for??

naveen

Former Member
0 Kudos

I will send a *.csv with the J2SE-Adapter to SAP XI, and i can not configurate the File-Adapter!

stefan_grube
Active Contributor
0 Kudos

You do not configure any sender adapter in XI directory, when you use J2SE adapter.

You have to configure the content conversion directly in the J2SE adapter.

See here:

http://help.sap.com/saphelp_nw04/helpdata/en/0d/00453c91f37151e10000000a11402f/frameset.htm

Regards

Stefan

Former Member
0 Kudos

Yes that is right!

I try ist, but it does not work!

Here the structure of the sender in XI in XML:

<?xml version="1.0" encoding="UTF-8"?>

<ns:PlaintMaintenanceMessagetype xmlns:ns="http://doehler.com/sapxi/krausdemosender">

<Data>

<item>

<EpuipmentID>1234</EpuipmentID>

<FunctionalLocation>Limo</FunctionalLocation>

<Data>20060105</Data>

<Time>sdf</Time>

</item>

</Data>

</ns:PlaintMaintenanceMessagetype>

an this is the structure of the J2SE-File-Adapter:

    1. file adapter java class

classname=com.sap.aii.messaging.adapter.ModuleFile2XMB

version=30

mode=FILE2XMBWITHSTRUCTURECONVERSION

#mode=FILE2XMB

    1. Integration Engine address and document settings (example, see docu)

XI.TargetURL=http://dauxsaph.da.doehler.com:8000/sap/xi/engine?type=entry

XI.User=******

XI.Password=*****

XI.QualityOfService=EO

XI.SenderParty=

XI.SenderService=Plant_Maintenance_Sender

    1. XI.ReceiverService=BW1CLNT001

XI.Interface=PlantMaintenanceMessageInterface

XI.InterfaceNamespace=http://doehler.com/sapxi/krausdemosender

file.sourceDir=C:/temp_bw

file.sourceFilename=fehler*

file.processingMode=delete

#file.retryInterval=20

file.pollInterval=5

##File Adapter specific parameters (example, see docu)

#file.type=BIN

file.type=TXT

#file.type=XML

file.encoding=UTF-8

xml.documentName=<ns:PlaintMaintenanceMessagetype xmls:ns="http://doehler.com/sapxi/krausdemosender">

#xml.documentName=http://doehler.com/sapxi/krausdemosender

xml.recordsetName=Data

xml.recordsetStructure=item,1

xml.item.fieldNames=EpuipmentID,FunctionalLocation,Data,Time

xml.item.fieldSeparator=,

#xml.keyFieldName=EquipmentID

#xml.keyFieldType=CaseSensitiveString

#xml.item.keyFieldValue=1234.

but it does not work why?

thanks yves

Message was edited by: Kraus Yves

stefan_grube
Active Contributor
0 Kudos

Hi Yves,

in the configuration file the XI client is missing.

Add a line:

XI.Client=<YourClient>

Regards

Stefan

Former Member
0 Kudos

That is not the problem, the message come to sap xi but the convertation of the text file to the xml file, which I make in the J2SE-File-Adapter are not right!

Here I need assistance!

yves

Message was edited by: Kraus Yves

stefan_grube
Active Contributor
0 Kudos

Hi Yves,

It would be helpful, if you let us know, what source you have and what result you expect.

Regards

Stefan

Former Member
0 Kudos

Hallo,

the source is a *.txt file:

1235,Cola,20060105,122030,

and the result is SAP XI, he is a structure like the XML File, what i post.

stefan_grube
Active Contributor
0 Kudos

Change following settings:

<b>xml.documentName</b>=PlaintMaintenanceMessagetype

<b>xml.documentNamespace</b>=http://doehler.com/sapxi/krausdemosender

Regards

Stefan

Former Member
0 Kudos

Thank you, it is runing!

But wehn i send to records in on file, what must i change?

xml.recordsetStructure=item,1 to xml.recordsetStructure=item,*

and

xml.keyFieldName=EpuipmentID

xml.keyFieldType=CaseSensitiveString

xml.item.keyFieldValue=1.

Is that right?

Can you help me?

Former Member
0 Kudos

How understand this what are the possibilities for me?

xml.keyFieldName=<fieldname>

xml.NameA.keyFieldValue=<valueInSubstructureName>

?

stefan_grube
Active Contributor
0 Kudos

Hi Yves,

When all records are identical I recommend using the simple conversion:

mode=FILE2XMBWITHROWCONVERSION

...

xml.documentName=PlaintMaintenanceMessagetype
xml.documentNamespace=http://doehler.com/sapxi/krausdemosender
xml.structureTitle=Data
xml.processFieldNames=fromConfiguration
xml.fieldNames=EpuipmentID,FunctionalLocation,Data,Time
xml.fieldSeparator=,

Your output would look like this:

<ns:PlaintMaintenanceMessagetype xmlns:ns="http://doehler.com/sapxi/krausdemosender">
	<Data>
		<EpuipmentID>1235</EpuipmentID>
		<FunctionalLocation>Cola</FunctionalLocation>
		<Data>20060105</Data>
		<Time>122030</Time>
	</Data>
	<Data>
		<EpuipmentID>1234</EpuipmentID>
		<FunctionalLocation>Limo</FunctionalLocation>
		<Data>20060105</Data>
		<Time>122030</Time>
	</Data>
</ns:PlaintMaintenanceMessagetype>

Would that work for you?

Stefan

Former Member
0 Kudos

Hallo,

with FILE2XMBWITHSTRUCTURECONVERSION it is not possible?

yves

stefan_grube
Active Contributor
0 Kudos

This is for when you have different structures like:

xml.recordsetStructure=item,*,anythingElse,*
xml.item.fieldNames=EpuipmentID,FunctionalLocation,Data,Time
xml.anythingElse.fieldNames=anyName

Here you can determine with your key fields, whether a line belongs to structure item or anythingElse.

When your line are the same structure in all cases, it is not possible to do so, as I assume there is no field with the same value in all lines.

Regards

Stefan

Former Member
0 Kudos

It is run,

but i change it:

mode=FILE2XMBWITHROWCONVERSION

...

xml.documentName=PlaintMaintenanceMessagetype

xml.documentNamespace=http://doehler.com/sapxi/krausdemosender

xml.structureTitle=Data

xml.processFieldNames=fromConfiguration

xml.fieldNames=EpuipmentID,FunctionalLocation,Data,Time

xml.fieldSeparator=,

xml.endSeparator=;

this are runing by:

<ns:PlaintMaintenanceMessagetype xmlns:ns="http://doehler.com/sapxi/krausdemosender">

<Data>

<EpuipmentID>1234</EpuipmentID>

<FunctionalLocation>Limo</FunctionalLocation>

<Data>20060105</Data>

<Time>122031</Time>

</Data>

<Data>

<EpuipmentID>1234</EpuipmentID>

<FunctionalLocation>Yves</FunctionalLocation>

<Data>20060105</Data>

<Time>122031</Time>

</Data>

</ns:PlaintMaintenanceMessagetype>

but not by:

<ns:PlaintMaintenanceMessagetype xmlns:ns="http://doehler.com/sapxi/krausdemosender">

<Data>

<EpuipmentID>1234</EpuipmentID>

<FunctionalLocation>Limo</FunctionalLocation>

<Data>20060105</Data>

<Time>122031</Time>

</Data>

<Data>

<EpuipmentID>1234</EpuipmentID>

<FunctionalLocation>Saft</FunctionalLocation>

<Data>20060105</Data>

<Time>122031</Time>

</Data>

<Data>

<EpuipmentID>1234</EpuipmentID>

<FunctionalLocation>Bier</FunctionalLocation>

<Data>20060105</Data>

<Time>122031</Time>

</Data>

<Data>

<EpuipmentID>1234</EpuipmentID>

<FunctionalLocation>Cola</FunctionalLocation>

<Data>20060105</Data>

<Time>122031</Time>

</Data>

</ns:PlaintMaintenanceMessagetype>

Why??

Thanks

Former Member
0 Kudos

It runs, thank you!

yves