Sender File Adapter Can I set original MessageID like SOAP Adapter??
Hello,PI Experts!!
I want to set original messageID(GUID) to Sender File adapter scenario.
SOAP Adapter can set original messageID with url, about FILE Adapter??
I think Adapter Module maybe can set original messageID.
best Regards,
Yuuki Fujioka.
Hello,
Yes, you can get Message ID with any adapter.
All neccessary information about approach you can find in links below:
Use getTransformationParameters().
Accessing Adapter-Specific Attributes
http://help.sap.com/saphelp_nw04/helpdata/en/43/03612cdecc6e76e10000000a422035/content.htm
Container Object
http://help.sap.com/saphelp_nw04/helpdata/en/78/b4ea10263c404599ec6edabf59aa6c/content.htm (String Mapping Runtime Constants: MESSAGE_ID)
Br,
Dzmitry
Similar Messages
-
Can we control the triggering of sender file adapter
Hi,
Can we control the tiggering of Sender file adapter with option of Run OS command before message processing
This option is available in Sender communication channel, what are the limitations of this option?
My actual requirement is to see the target folder whether it is empty or not, if empty then I can trigger the interface.
For this I want to write shell script whihc execute at OS level to check whether the target is empty or not, But the constraint is will this can control the triggering of sender adapter.Hi Sekhar,
I guess this can help you control the file pick up.
If your shell script works well then using the same you can modify the filename or its extension if the target folder is empty.
Say in the sender file adapter you set the source-filename as "inbound_*.ready". Now when originally the source file is dropped into the source folder (by any other process) let it be named as "inbound_001.pending" and your script will change the file name to "inbound_001.ready" if the target directory is empty. I dont think you need to use the pre processing OS command for this.
Does it make any sense?
Regards,
Suddha -
Which file fails in sender file adapter
Hi.
Is there a place in the monitoring landscape, that can tell me the filename of a file, that fails in a sender file adapter (lets say I receive files with filename *.txt).
The file adapter uses content conversion.
Right now, the RWB only tells me that something went wrong in the content conversion. The filename would be nice for people working in a CCC to forward to second level support!
Regards...
PeterHi,
In the sender file CC..
Check the option filename and filetype under the adapter specific attribute so that the payload will have the filename too...which make the life easy...
Regards
San
Remember to set the thread to solved when you have received a solution there is a Way. -
Problem in Sender File Adapter using FCC with Variable structure
Hi Experts,
Hi Experts,
I have facing an issues while using FCC in Sender File adapter. Below are the configs for the same:-
Recordset structure required is ==HEADER,1,DATA,*,TRAILER,1
Recordset per message == *
Key Field Name == Key
(Sorry i dont know how to insert screen shot here..pls tell me how can i insert screen shots here on sdn)
HEADER.fieldSeparator ,
HEADER.endSeparator u2018nlu2019
HEADER.fieldNames Key,x,y,zu2026
HEADER.keyFieldValue 1
HEADER.keyFieldInStructure ignore
HEADER.fieldContentFormatting trim
HEADER.additionalLastFields ignore
HEADER.missingLastFields ignore
DATA.fieldSeparator
DATA.endSeparator
DATA.fieldNames
DATA.keyFieldValue
DATA.keyFieldInStructure
DATA.fieldContentFormatting
DATA.additionalLastFields
DATA.missingLastFields
Using same variables for Trailer record as well.
Source CSV file which i am picking:-
ADSE ,RASD,replan Contact ,2 0080509 0 8:43:25 ,
EMPL ,0011111, S Top Up ,20080401 ,20080430 ,sdf , 00000000431250 ,2007 , , , , , ,20080414 18:07:35,
EMPL ,0222222, r Cash Award ,20070701 ,20070703 ,ded , 00000000023509 ,2007 , , , , , ,20080414 18:09:31,
EMPL ,0233333, Cash Award ,20070801 ,20070831 ,df , 00000000044057 ,2007 , , , , , ,20080414 18:10:56,
EMPL ,0244444, Cash Award ,20080101 ,20080111 ,sf , 00000000026717 ,2007 , , , , , ,20080414 18:08:29,
BTRL , 5140,
When i tested the scenario and monitored it using MDT in CC monitoring tool its giving me below mentioned error.
The XML page cannot be displayed
Cannot view XML input using style sheet. Please correct the error and then click the Refresh button, or try again later.
XML document must have a top level element. Error processing resource 'http://myurlname/mdt/me...
However if i change the occurence of DATA as some specific value for eg 4 instead of * it works fine.
Kindly help me in solving this problem.
Thanks,
Aditya VermaHi Madan,
Thanks a lot for giving me the way to this. But when i tested this with the below file its giving me the same error. Please let me know if i need to do any changes to the parameters mentioned above:-
ADSE ,ASDA,Sha replan Fr ont Feed Contact ,2 0080509 0 8:43:25 ,
EMPL ,0011111, Cash Top Up ,20080401 ,20080430 ,TPV , 00000000431250 ,2007 , , , , , ,20080414 18:07:35,
EMPL ,0222222, r Cash Award ,20070701 ,20070703 ,TPV , 00000000023509 ,2007 , , , , , ,20080414 18:09:31,
EMPL ,0233333, r Cash Award ,20070801 ,20070831 ,TPV , 00000000044057 ,2007 , , , , , ,20080414 18:10:56,
EMPL ,0244444, Cash Award ,20080101 ,20080111 ,TPV , 00000000026717 ,2007 , , , , , ,20080414 18:08:29,
EMPL ,0255555, Cash Award ,20080301 ,20080320 ,TPV , 00000000027870 ,2007 , , , , , ,20080414 18:08:25,
EMPL ,0266666, Cash Award ,20071001 ,20071020 ,TPV , 00000000020681 ,2007 , , , , , ,20080414 18:09:31,
EMPL ,0877777, Cash Top Up ,20080401 ,20080430 ,TPV , 00000000036000 ,2007 , , , , , ,20080414 18:07:05,
EMPL ,0888888, Leaver Cash Award ,20071201 ,20071231 ,TPV , 00000000157200 ,2007 , , , , , ,20080414 18:11:29,
EMPL ,0899999, S Leaver Cash Award ,20080301 ,20080331 ,TPV , 00000000153530 ,2007 , , , , , ,20080414 18:07:42,
EMPL ,0800000, S Leaver Cash Award ,20070701 ,20070731 ,TPV , 00000000012234 ,2007 , , , , , ,20080414 18:08:34,
BTRL , 5140,
This the original csv file which i'll get in live. Kindly suggest as ur solution worked with other file but not working with this scv file.
Thanks a lot,
Aditya. -
Is Sender File Adapter always throws error when there is no file?
Hi,
I have a simple question but can't find a straight answer to it. I have a Sender File adapter that configured to pick up file XXX* from FTP server every 1 hour. But a file can come every 2, 3, or 7 hours- no certain time.When there is no file I got "File not found " error. As we use alerts, this behaviour is not acceptable.
Does this error comes always if there is no file? Any possible way to avoid this error ?
Thanks for help.
NataliyaHi Ravi,
I can see the error in Runtime Workbench under CC monitoring. To be precise it says:
An error occurred while connecting to the FTP server '1X.1XX.XX.XX:21'. The FTP server returned the following error message: 'com.sap.aii.adapter.file.ftp.FTPEx: 552 RMS-E-FNF, file not found, ES4_SAP*'. For details, contact your FTP server vendor.
My ftp server has the following set up:
Server: xx.xxx.xx.xx
Port:21
Dataconnection:Active
Timeout:120
Connection secuirity: None
User name .... etc set up.
Connect mode: Per file transfer
Transfer mode:Text
QoS:EO
Pollinterval: 120 (for test purposes)
Processing Mode: delete
Can it be that its a ftp server generates error and sends back to XI?
Thanks,
Nataliya -
Sender File Adapter - Dynamic Filename?
Dear All,
I have a simple requirement to retrieve a file named "XXX_ddmmyy" from an FTP site. The FTP site administrator will place a new file everyday. The date is part of the filename.
I can find a lot of information on how to set the Filename for a "Receiver File Adapter", but none about dynamically setting of the filename for a "Sender File Adapter".
Can you help please?
Kind Regards
FarshadHi,
You have mentioned over here that the requirement is to get the file "XXX_ddmmyy" from an FTP site.
Is that site strictly for keeping files related to your requirement only or lot of other files are also being placed???
If its strictly related to your requirement then you can use the filename "*.extension" and set the processing mode as "delete" so that once the File Adapter picks the file it will be automatically deleted.
But here disadvantage is that the file wont be no longer present in FTP site once it is picked by File adapter.
Thanks,
Lekshmi. -
Sender File Adapter - Content Conversion
HI Friends,
I got a scenario where I need to convert the File to XML document through Sender file adapter..
My file looks like below.
BATCH1234........
12DASER123142JMM
237DSAFDLKC839890
45SDFLASJ90011
BATCH3455...
132FGAR
SD21352525
BATCH998898...
123145DSRTW
12FSTS
So there is a Header and Body for each record set..
My XML Structure is as follows.
<TimeStructure>
<TimeRecord>
<ControlRec>
<Field1>BATCH </Field1>
<Field2> ...</Field2>
</ControlRec>
<DataRec>
<F1> ...... </F1>
<F2> ...... </F2>
</DataRec>
</TimeRecord>
<TimeRecord>
<ControlRec>
<Field1> BATCH </Field1>
<Field2> ADFAS </Field2>
</ControlRec>
<DataRec>
<F1> ...... </F1>
<F2> ...... </F2>
</DataRec>
</TimeRecord>
</TimeStructure>
The blog <a href="/people/shabarish.vijayakumar/blog/2006/02/27/content-conversion-the-key-field-problem:///people/shabarish.vijayakumar/blog/2006/02/27/content-conversion-the-key-field-problem
is somewhat relevant to my requirement.
But the problem is I have the keyfield "BATCH" for my header file but don't have any <b>key field in the data record</b> of the input file.
Please help me out how to mention the configuration parameters.
Regards,
KumarHi,
If you don't have constant key value for your detail records, then you can not directly get the required xml.
So in this case, you can read all the records in a common Row model, i.e each record will be considered as a one row with all the values, and then split this row with Substring or java functions in the mapping.
Even you can do this in the Adapter module .
If you have key value for each record to identify then you can try with content conversion.
Regards,
Moorthy -
Sender File Adapter : File Name Determination
Hi All,
My Scenario :
1) Im my scenario i need only the "FileName" of the File when picked up by the Sender File Adapter.
2) Rest Content of the File need not be in the XML file format.
Now what i did was developed "File Adapter Module " to get the "FileName" when picked up by the Sender File Adapter.
Outcome : When i put the developed module at first and put the file in specified folder allowint the Sender file Adapter to pick up. Now Everything is fine working when one kind of File is placed as per my Content Coversion paramaters.
Actual : My Client would place file of any kind (.jpeg -> Mostly , gif ) i need to get only the file name in the Outbound interface , which i would split it further to my Target Interface.
How could i achieve this , when i took away this content conversion , in sxmb_moni it shows error.I need only the filename in the Outbound not the Content , moreover the hit is i donot know what could be content of my file as it could be different and varing , so i could not set particular content conversion paramters:
Second Question:
Now my outbound XML interface looks as below when i test with a file , with proper content conversion paramerters:
<?xml version="1.0" encoding="UTF-8" ?>
- <MT_DMS_FINAL>
- <Record>
- <Row>
<FirstName>2323_eer_rtr</FirstName>
</Row>
</Record>
<FileName>d:\mdmtest\srinivaS\padusrini.txt</FileName>
</MT_DMS_FINAL>
Well i have designed in my MI only FirstName , how to capture this element "FileName" which i can use it in mapping , if i have to write any UDF to capture it ,please guide me.
thx in advance for u r help
with regards
SriniHi Guys ,
Can i use File Content Conversion for .pdf document , my pdf doc content is not known, means it"s a complete info doc.I may get .jpeg any picture or drawing.
I thought i can use below file content conversion paramters:
Document Name : MT_DMS_FINAL
RecordSet Name : Record
RecordSet Structure : Row,*
Row.fieldNames - FirstName
Row.fieldSeparator - ;
Row.processFieldNames - fromConfiguration
Row.additionalLastFields - ignore
Row.missingLastfields - ignore
Now i put a pdf doc of unknown content , and my assumption was some set of charater would be dumped in XML and rest would be ingonered which is least bothered part in my scenario , unless i get the filename from runtime ot Adapter module developed
But in RWB CC monitoring i see below error :Error: org.xml.sax.SAXParseException: Illegal XML character: .
Any views on this , can any one help me out with the above requirment. Hope u guys got wat am trying to put out here
thx in advance for u r help
with regards
Srini -
Sender File Adapter- Incrementing the counter in file name
Hello,
We have a requirement to read a different file name with every read. Every subsequent file would have a numeric counter updated when we receive it, we need to read that file as the directory would hold the previous files as well.
File structure :- EP<counter>.txt ; so first file would be EP001.txt, next one would be EP002.txt.
How could i do this in Sender file adapter, as there is no variable substitution available like receiver file adapter.
I cannot use wild card characters as the directory would contain previous files as well and we ned to pick the latest file.
RegardsHi,
>>How could i do this in Sender file adapter, as there is no variable substitution available like receiver file adapter.
Yes true this is not available in sender channel
>>I cannot use wild card characters as the directory would contain previous files as well and we ned to pick the latest file.
You can use EP* as the filename and use processing mode as Set to Read-Only
Regards
Suraj -
Sender File Adapter - FCC - No incoming field separator - How to do FCC?
Hi,
I have a sender File adapter and I need to do the File Content Conversion but there apparently no incoming field separator and the file ocntains just running text - no data records but just information.
For example the incoming file is something like:
The Hongkong and Shanghai Banking Corporation Limited 27JAN2009 PAGE 1
Incorporated in Hong Kong with limited liability
ABC IAL LIMITED ABU DHABI, UAE
ABC MIDDLE EAST Account No. 001-8888888
ABU DHABI Payment Set AAA
BBB MAIL BOX NO.99 Contact Person ABC LIMITED
7777777777 Telephone
AUTOPAY LIST - PROCESSED
(AUTOPAY-OUT SALARY)
Payment Date 27JAN2009
First Party Narrative . 66666666
Second Party Narrative .
The Message type that I am mapping to contains:
MT_XXXX
WA
Item
Item2
Item3
This is so that the information can be mapped to different field areas and send across to the Receiver Mail Adapter. In the mail i receive, i get the running text. I tried giving the field separator as '0x09' but it is not working.
I have also tried WA..fieldContentFormatting to nothing but again no luck.
I have tried with Recordset Sequence with Ascending and variable and have also tried Recordsets per Message with * and blank - but it did not help.
Please advice.
Regards,
ArchanaHi,
I assumed that it was tab but when I made the change in FCC, it did not work.
I would still like to have a output where it looks like below if more than 2 types of information in 1 line as below:
ABC IAL LIMITED ABU DHABI, UAE
ABC MIDDLE EAST Account No. 001-9999999999999
and not something like:
ABC IAL LIMITED ABU DHABI, UAE
ABC MIDDLE EAST Account No. 001-999999999999
I am not sure what to do here.
Help please.
Regards,
Archana -
Sender file Adapter, problem with proxy authentication
HI all,
i'm having some problems with the following scenario, i need to configure a sender file adapter which connects to a FTP server. To connect this FTP server i need to set a proxy (and so a username and a password), and i don't know how to do.
From note 821267 seems that the proxy is not supported for an FTP adapter, but the are some workaround like the ones described in the following link
Re: Proxy server inFTP adapter
http://wiki.sdn.sap.com/wiki/pages/viewpage.action?pageId=57137
They don't work in my case as i need to se two username (the one for proxy and the one for the ftp server) and i cannot force the proxy use for all XI applications.
Can anyone help me?
Thanks a lot
AldoProxy is necessary to exit the customer local intranet. It's not possible to go outside network without going through the proxy server.
I cannot set the proxy server in file adapter as it's not supported like described in SAp note, a possible workarounf is to force the proxy server in the J2ee stack but in this way all PI calls would use that proxy.. -
Sender File Adapter is not reading anything
Hi,
I have a really strange problem here. I'm tyring to read a file using file adapter (FTP) and the adapter doesn't read anything and it does not throw any error in the communication channel monitoring.
I'm using a receiver file adapter to write files to the same FTP folder, so it can't be a connectivity problem. And I tried to get the file using Filezilla and it works fine...
In the sender file adapter I tried to simplify the maximum to solve the problem:
- NO File Content Conversion
- NO advanced attributes
- I used the "*" in the file name to read any file
- I've only configured the FTP connection, the folder and the file name. I don't understand why it isn't working...Yes I got this message:
Polling interval started. Length: 5,0 seconds
Now I tried something... In the FTP Connection parameters, I set as the server a random and unexisting name, and I get the same result...
I'm starting to thing that some firewall is blocking the connection, but I have to wait until next monday to know this. But I don't understand why the receiver FTP channel is working...
PD: The cache is correctly refreshed because I changed the polling interval time, and it has been updated on the monitoring -
Send a mail if no file in Sender File Adapter
Hello guys,
I have one doubt. I have a sender File adapter with FTP transfer protocol. I want to pull the file every 24 hours. If the file does not exist, there is any way to have an error and send a mail to the client?
Is a requierement to do one interface, they want that XI sends a mail if no file is encounteref in the server when XI goes to pull the file. Is this possible?
Many thanks in advance.
Regards,
Xavi.Hi,
Refer to following link
Read Excel instead of XML through FileAdapter
This has good example of developing module. Only code is available. For further help you can look in Help.sap for crating module they also provide sample code.
No need to call alert from module . go upto 24 hars if no file is received set your own structure.
Give condition in receiver detrmination to send mail if file is not picked.
revert back for any clearity.
Thanks
Sunil Singh -
Sender File Adapter: No Messages
Hi,
I have configured a sender file adapter to read a flat file using file format conversion, in the file poler mode using NFS. I could confirm that the File is being read, and the adapter status from the Adapter framework (is:port/AdapterFramework) indicates the adapter is working fine (Green light, and last message processed at XXX........).
However, I did not find any messages from SXMB_MONI.
Further, I got inot the RWB, and found the following Audit log:
It indicates an error "Transmitting the message to endpoint http://kansbwul01:50000/sap/xi/engine/entry?action=execute using connection AFW failed, due to: Received HTTP response code 404.."
What is the problem, and how can I resolve it?
Thanks
Feroz
Success Channel CDWFileReader: Entire file content converted to XML format
Success Send text file "/tmp/XIDemo/3315-TL-20041126-0000IN.txt", size 164533, character encoding ISO8859-1 with QoS EO
Success Application attempting to send an XI message asynchronously using connection AFW.
Success Trying to put the message into the send queue.
Success Message successfully put into the queue.
Success The application sent the message asynchronously using connection AFW. Returning to application.
Success Confirmation mode test found. File will be resent next time
Success The message was successfully retrieved from the send queue.
Success The message status set to DLNG.
Error Transmitting the message to endpoint http://kansbwul01:50000/sap/xi/engine/entry?action=execute using connection AFW failed, due to: Received HTTP response code 404..
Success The asynchronous message was successfully scheduled to be delivered at Sun Jan 09 19:13:21 CST 2005.
Success The message status set to WAIT.Hi,
Further to my earlier post, the following is the message log from the message monitor. Any clues whats going wrong. Can I configure a File Sender->File Receiver scenario?
Where and how are the port settings and user credentials configured for the AFW.
-Feroz
Message ID f49f6d21-632c-11d9-805a-0003ba54d619
RefToMsg ID
Conversation ID
Sequence Number 0
Message Type Asynchronously Sent Message (SEND)
From Party
From Service Name: LB1_CDWFilePoler
To Party
To Service Name: LB1_CDWFileWriter
Action Namespace: http://erc.ge.com/cdw/poc Name: ReadFile
Connection Name AFW
Status Not Delivered
Profile XI
Transport HTTP
Delivery Semantics Exactly Once
Times Failed 4
Number of Retries 3
Sent / Received 01/10/2005 12:42:33
Transmitted / Delivered 01/10/2005 12:57:33
Next Delivery 01/10/2005 12:57:33
Persist Until 02/09/2005 12:42:33
Valid Until
Retry Interval 5 Minutes
Address http://kansbwul01:50000/sap/xi/engine/entry?action=execute
Credential SAPPasswordCredential(XIAFUSER):password=********:sapclient=100:saplang=
Transport Headers SOAPAction="http://sap.com/xi/XI/Message/30" Content-Type=Multipart/Related; boundary=SAP_63fa9d21-6337-11d9-8f3c-0003ba54d619_END; type="text/xml"; start="" HTTP=POST
Node ID 1485750 -
Sender File Adapter - Fixed Length
We have a Fixed File(Sender). With 3 fields. NO Header. Space is the separator for each fields
VendorNumber 10 bytes
VendorName 10 bytes
City 5 bytes
In the File we can have multiple records.
The Root Node is Vendor.
I am trying to define the SENDER FILE ADAPTER in the following way (I have referred mostly all the blogs) but my file is not picking up for some reason.
File looks like this
V123456789 A123456789 Bosto
V234567890 B123456789 Atlan
V334587900 C123456789 Austi
Note : I have been asked to give the Transport Protocol as "NFS" (Whether this is the problem???) I have summarised the complete details below. Please help me
Adapter Type : File Sender
Transport Protocol : NFS
Message Protocol : File Content Convervsion
Adapter Engine : Integration Server
FILE ACCESS PARAMETERS
Source Directory : /business
file Name : vendor.txt
Content Conversion Parameters
Document Name : Vendor
Document NameSpace: http://sap.com/xi/XI/SplitAndMerge
Recordsetname : Message1
Record Structure : File_MT,*
Recordset Sequence: Ascending
Key Field type : String(Case Sensitive)
Additional Parameters
File_MT.fieldFixedLengths 10,10,5
File_MT.fieldNames VendorNumber,VendorName,City
File_MT.fieldSeparator
File_MT..processFieldNames fromConfiguration.Hi Naveen,
Do check the following things,
>>Note : I have been asked to give the Transport Protocol as "NFS" (Whether this is the problem???) I have summarized the complete details below. Please help me
1.If your file resides on your local network/local computer give NFS(Network file system). if your file resides on a FTP location give FTP and also give the FTP log on parameters.
Additional Parameters
File_MT.fieldFixedLengths 10,10,5
File_MT.fieldNames VendorNumber,VendorName,City
File_MT.fieldSeparator
File_MT..processFieldNames fromConfiguration
2.If this structure does not match with the input file structure the file adapter wont pick up the file. So check for the help document provided by SAP in the following path.
help.sap.com --> Documentation --> SAPNetWeaver --> SAPNetWeaver '04 --> English --> process integration --> SAP Exchange Infrastructure --> connectivity --> Adapters --> File Adapter
Your file contains three records
V123456789 A123456789 Bosto
V234567890 B123456789 Atlan
V334587900 C123456789 Austi
You have mentioned the fieldSeperator as space but there is no File_MT.endSeparator '/n' which differentiates between each and every row (record).
Parameters for Record set Structures mentioned in the sender adapter configuration does not match with the actual file structure .
Try giving exact structures in the configuration of sender file adapter.
regards,
Aravindh.
Maybe you are looking for
-
What is General Error (41)
Ill work longgg and hard on a project only to try and open it open after i've saved it and try to come back to it to finish it and ill get the alert: general error (41) What is that and how do i fix it once and for all?
-
Pre10 crashes, hangs, and "Error compiling movie. Unknown error."
I'm using Premiere Elements 10.0 and an am having a lot of trouble. On a simple project (just half a dozen video clips with audio and some DVD menu stuff) I din't have much trouble. However my bigger project (which is the reason I bought PRE10) isn'
-
Visited a secure site to renew my membership, but there was no indication on FIREFOX WINDOW that the site was secure. Whereas, when using Internet Explorer the usual padlock symbol was displayed.
-
Logging same NC code for multiple components
Hi, When logging NC codes in SAP ME 6.0 it is possible to log the same NC Code (defect) against many ref-des for multiple components. However when logging a secondary code (Action) for the previous primary NC Code all the choosen ref-des and componen
-
Can not type in blanks of an online form
When I try to type in lines of online form, my computer keys do not work. What do I need to do to complete online forms?