File Content Conversion: Sender Problem
Hi,
I'm getting a very typical error in my Sender Communciation channel.
Channel CC_FILE_SENDER_2: Empty document found. Proceed without sending message
I've gone through a few threads and I know that the problem is with the Key Field and using * in the Recordset Structure but I cannot solve it. If I use * in the Recordset structure it fails,when I use a specific number it works. Any ideas
Here is my Communication Channel details
Document Name: MT_SENDER
Document namespace: http:\\sender
Recordset Structure: FileHeaderRecord1,1,FileHeaderRecord2,1,FileHeaderRecord3,1,FileDetailRecord,*,FileTrailerRecord1,1
Recordset Sequence: Ascending
Key Field Name: RType
And the configuration:
FileHeaderRecord1.fieldNames: RType,Filler,Code,Filler2
FileHeaderRecord1.fieldFixedLengths: 10,31,6,69
FileHeaderRecord1.keyFieldValue: V
FileHeaderRecord2.fieldNames: RType,Filler
FileHeaderRecord2.fieldFixedLengths: 3,113
FileHeaderRecord2.keyFieldValue: HDR1
FileHeaderRecord2.fieldNames: RType,Filler,Date,File,Filler2,Num,Filler3
FileHeaderRecord3.fieldFixedLengths: 3,2,5,6,21,3,76
FileHeaderRecord3.keyFieldValue: UH1
FileDetailRecord.fieldNames: RType,Filler,TCode,Filler1,Amount,Filler2,ZGC,Filler3,Date,Filler4
FileDetailRecord.fieldFixedLengths: 14,1,2,18,11,18,9,28,5,10
FileDetailRecord.keyFieldValue: 9
FileTrailerRecord1.fieldNames: RType,Filler,TCode,Filler1,Date
FileTrailerRecord1.fieldFixedLengths: 14,1,2,12,5
FileTrailerRecord1.keyFieldValue: UT1
ignoreRecordsetName: true
This is a copy of my file....
VPR456SCL1 852086
HDR1 SED456RD 345344500428 F 04 094520428 BS 09452
UHL1 09452ESBCL1 00000000 004
85208681123787085 000000000000500FREW RTYU POSWS123704375 09452
85208681123787085 000000000000600FREW RTYU POSWS123705307 09452
85208681123787085 000000000000600FREW RTYU POSWS123705671 09452
Hi,
problem is in your keyfield value,
FileHeaderRecord1.fieldNames: RType,Filler,Code,Filler2
FileHeaderRecord1.fieldFixedLengths: 10,31,6,69
FileHeaderRecord1.keyFieldValue: V
keyfield name is RType and it is given a fixedlength of 10 characters, but your keyfieldvalue is "V
" which is not 10 char long that is the reason your adapter is failing to pick it.
same for all the other recordsets, the fieldvalue shd match the fixed length given.
Eg:- give keyfieldvalue like this "V ". it will work.
Similar Messages
-
File content conversion sender adapter
Hi Friends,
I am doing File to IDoc scenario.
I am using File Content Conversion for File Adapter.
My structure look like this
MT_File
HEADER1 1..1
--header1
-- header2
HEADER2 1..1
--header3
DETAILS 1..unbounded
--details1
--details2
--details3
TRAILER1 1..1
-- trailer1
TRAILER2 1..1
-- trailer2
----trailer3
In File Content conversion parameeters..
Document Name :MT_File
Document Namespace :urn:test:FileFcctoIdoc
RecordSet name :
RecordsetStructure :HEADER1,1,HEADER2,1,DETAILS,*,TRAILER1,1,TRAILER2,1
RecordSet Structure: Ascending
RecordSet Per message : *
Key Field Name :header1,header3,details1,trailer1,trailer3
ignoreRecordsetName : true
HEADER1.fieldNames :header1,header2
HEADER1.keyFieldValue : H1
HEADER1.fieldFixedLengths :5,10
HEADER1.endSeparator :'nl'
HEADER2.fieldNames :header3
HEADER2.keyFieldValue : *D
HEADER2.fieldFixedLengths :5
HEADER2.endSeparator :'nl'
DETAILS.fieldNames :details1,details2,details3
DETAILS.keyFieldValue : 3
DETAILS.fieldFixedLengths :5,5,5
DETAILS.endSeparator :'nl'
TRAILER1.fieldNames :trailer1
TRAILER1.keyFieldValue : *S
TRAILER1.fieldFixedLengths :5
TRAILER1.endSeparator :'nl'
TRAILER2.fieldNames :trailer2,trailer3
TRAILER2.keyFieldValue :SE TRAILER2.fieldFixedLengths :5,5
TRAILER2.endSeparator :'nl'
File is :
H1hh1hhhhhhhhh2
*Ddd*
Xddd1dddd2dddd3
Xddd4dddd5dddd6
Xddd7dddd8dddd9
*Sss*
SEKss2
in RWB, Channel CC_FILE_Sender_FccDemo: Empty document found. Proceed without sending message
I think the problem is in FCC paramters..
Could please have a look and correct me
Regards
RamRam,
The problem which i can see is your key field values in your test file. Remember you should have the key field value in each new line at the same place.
For example you have given your text file as shown below...
File Given By You is :
>H1hh1hhhhhhhhh2
>*Ddd *
>Xddd1dddd2dddd3
>Xddd4dddd5dddd6
>Xddd7dddd8dddd9
>*Sss *
>SEKss2
Compair the above file with the below one..
>H1hh1hhhhhhhhh2
>*Ddd *
>Xddd1dddd2dddd3
>Xddd4dddd5dddd3
>Xddd7dddd8dddd3
> *Sss *
>SEKss2
If you notice, for details I have given key field value 3 in each line & at same place.
One more thing just use the KeyFieldName only one ( just follow the same blog which I have given, to understand how to use the KeyFieldName )
e.g.
Document Name :MT_File
Document Namespace :urn:test:FileFcctoIdoc
RecordSet name :
RecordsetStructure :HEADER1,1,HEADER2,1,DETAILS,*,TRAILER1,1,TRAILER2,1
RecordSet Structure: Ascending
RecordSet Per message : *
Key Field Name : KF
Regards,
Sarvesh -
File content conversion - sender adapter for Header and detail records
Hi Experts,
I am receiving a field of fixed length content format.(Header)The first line of the file will follow the structure X having some fields and (DetailRecord)subsequent lines in the file will follow structure Y having somes fields.There is no record identifier for Header and Detail records.In one file first line is Header records and remaining subsequent line is DetailRecord.What are the parameters we have to set for sender file content conversion parameters as i donot have any key field and key field value.And in one file we have only one header records ( first line) and n number of detail records from 2nd line onwards.
Thanks
DeepakHi
Refer the below fourm link,
Flat file whitout id
Regards
Ramg. -
Strange Problem with File Content Conversion (Sender)
Hi,
I have a strange problem. I have a sender file adapter with content conversion (csv -> xml). The adapter produces the following error during the processing...
- 2006-02-06 16:34:00 CET: Error: Conversion of part of file content of 'OE_Extractor_47_ISW112_SC-Ireland.csv' to XML format failed around position 1202: IOException: Stream closed
After the 4th or 5th try the adapter processes the file correctly.
Why does it works after several tries and not at the first time? (The file is not changed during the adapter is trying to convert it)
Thanks
ThomasI found the problem, something was wrong with the ftp server
-
File Content Conversion (Sender) endSeparator Problem
Hi
i have a flat file like this:
fieldA;fieldB;fieldC;fieldA;fieldB;fieldC;fieldA ...
recordset structure: FIELDS,1
recordset per msg: *
parameters:
FIELDS.fieldNames = fieldA,fieldB,fieldC
FIELDS.fieldSeparator = ;
FIELDS.endSeparator = ;
if i change the endSeparator to 'nl' and then changeing the input file to this:
fieldA;fieldB;fieldC
fieldA;fieldB;fieldC
fieldA ...
it works. i already tried to use another endSeparator like this:
fieldA;fieldB;fieldC:fieldA;fieldB;fieldC:fieldA ...
but it doesn't work. it seems like the adapter is only using 'nl' endSeparator, no matter whats the parameters say.
the error in adapter monitoring:
Error: Conversion of complete file content to XML format failed around position 0 with java.lang.Exception: ERROR converting document line no. 1 according to structure 'FIELDS':java.lang.Exception: ERROR in configuration: more elements in file csv structure than field names specified!
i already tried to use hex separators and found the following thread (best matching tread):
anyone has an idea? Thanks a lot.
Regards
J.
Message was edited by: Jörg Pieper
Message was edited by: Jörg PieperHi
this doesn't work
Regards
J. -
File Content Conversion : Sender Channel
Hi
I am trying to do content conversion in the Sender Channel from a flat file to a XML.
My Target XML(message structure) looks like
<H1>
<H2>
<D>Detail Record</D>
<L1>line</L1>
<L1>line</L1>
</H2>
<H2>
<D>Detail Record</D>
<L1>line</L1>
<L1>line</L1>
</H2>
</H1>
Here the element <H2> is only needed to group <D> and the following <L1> elements of each new occurrence of <D>.
Now my problem is that the element <H2> is not getting created.
and the message after content conversion is looking as follows
<H1>
<D>Detail Record</D>
<L1>line</L1>
<L1>line</L1>
<D>Detail Record</D>
<L1>line</L1>
<L1>line</L1>
</H1>
What should I do to get the desired result.@Yes Bhavesh you are right.
Hi Jai,
I am trying the other way round.i.e from flat file to a XML message.As I said I was trying to do it for Sender Channel where is the after content conversion I want a XML file.The example is a what I framed out of my actual problem.
if flat file is as follows ,
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
DetailRecord1
Line1
Line2
Line3
DetailRecord2
Line4
Line5
then the XML must look like
<H1>
<H2>
<D>DetailRecord1</D>
<L1>Line1</L1>
<L1>Line2</L1>
<L1>Line3</L1>
</H2>
<H2>
<D>DetailRecord2</D>
<L1>Line4</L1>
<L1>Line5</L1>
</H2>
</H1>
I identify the different types records in the flat file
as follows,
Record starting with "Detail" is considered as <D> element
Record starting with "Line" is considered as <L> element.
Hope I did clarify. -
File Content Conversion Sender. Enclosured info
Hi experts,
I have to read a plain file like this:
x
x
x
x
x
<START-OF-FILE>
a;b;c;d;
a;b;c;d;
a;b;c;d;
<END-OF-FILE>
x
x
x
x
x
Where 'x' means unuseful and unformatted lines, and 'a','b','c','d' are the fields to be parsed to xml.
I wonder whether there is a way, using FCC in the file sender adapter, to gather only the lines enclosured between '<START-OF-FILE>' and '<END-OF-FILE>'. There is no key field I can use.
Many thanks in advance,
PacoHi Francisco,
I think u need to write a UDF to achieve the requirement.
And, I think there is a possibility to do it using content conversion.
Use set NameA.fieldFixedLengths for the unused data in the file.
use NameA.fieldContentFormatting - Enter trim to remove all the leading and subsequent blanks for a value found. This is the default.
If there is any field length restriction use NameA.fieldFixedLengths.
NameA.fieldSeparator & NameA.endSeparator shoulf be used.
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.
I hope this info will help you.
Refer the below link:
http://help.sap.com/saphelp_nw70ehp1/helpdata/en/2c/181077dd7d6b4ea6a8029b20bf7e55/content.htm
Regards, -
.csv file Vs .txt file Content conversion sender file channel
Hi Experts,
I have a file with filename say input.csv.I want to do content conversion for these .CSV file.Is it same like we have to do for .txt file say input.txt.
when i open my .csv file in notepad, i get multiple rows with each field separated by ';'.what are the content conversion parameters we have to define for .csv file and can we mention input.csv as the file name as a source file name.
Thanks
DeepakHi,
Use the following parameters for Sender file channel in case of reading .csv file
Recordset Structure.fieldSeparator -
Recordset Structure.endSeparator -
'nl'
Recordset Structure.fieldNames -
provide field names separated with ,
Regards
Seshagiri -
File Content Conversion - Sender File Adapter - Record Delimeter ~
The inbound file has file has ~ as record delimeter. I am using the FCC at sender file adapter to covert this file into XML. Somehow, the file adapter is not able to interpret "~" as my record delimeter even thoough I specified "record.endSeparator = ~" in FCC.
Would someone help me with a solution?Raju,
You can also try to use the '0x7E' as endSeperator condition.
I am not sure if the HTML tag will work but this should do the trick. This should be the HEX corresponding entry
char description hex char code html
" ~ " "Tilde" "0x7e" "~" &!tilde; (without !)
greets.
in adition to this see SAP help
http://help.sap.com/saphelp_nwpi71/helpdata/en/44/655453b48a4ddfe10000000a1553f7/frameset.htm
Special Characters in Strings for Separators
In all strings for separators (NameA.fieldSeparator, NameA.beginSeparator, NameA.endSeparator), you can specify non-printable ASCII characters. These characters can each be inserted individually in the strings in the form ´0xHH´ (including the quotation marks), where HH represents the character encoded as a hexadecimal value.
Please also ensure that the "recordSet Structure" also need to be configured Correctly
for example:
Header,1,Detail,*
Header.fieldSeperator --> %parameter%
Detail.fieldSeperator --> %parameter%
Detail.endSeparator --> '0x7e'
Greets -
File Content Conversion Mapping problem
Hi,
I tried a file to file simple scenario using FCC on the Sender Side,but I repeatedly get a message mapping error.
I tried changing the different parameters in filesender file adapter, checked message mapping for errors .
1.My Mapping is Correct.
2.The parameters in the FCC are correct.
Is there any way where we can debug the the Message Error.
Regards,HI,
but I repeatedly get a message mapping error.
what error message ur getting.
what is ur file strucutre
what FCC u r using.
give me the details
chirag
Hi,
These are the following details:
1.error message: There is an exception in mapping
2. File structure: A comma separated text file
e.g : Somya, 24.
3. I am using sender file FCC.
My data type is as follows:
FileInput
Recordset
Row
Name
Age
The Sender FCC used is:
Document Name: FileInput
Recordset Name: Recordset
Recordset Sturcute: Row,*
Row.fieldNames: Name,Age
Row.fieldSeparator: ,
Row.endSeparator: 'nl'.
Do Help.
Regards, -
File content conversion:move files to a new directory
hi all,
I have a file content conversion sender and receiver scenario.Now my doubt is: XI is running on sap27 server.Input file is being created by an ABAP program in r/3 and file being put in sap29 server.
In source directory if i am giving the sap29 path it is not working.Is there any way that i can write a OS command to move files from 29 to 27 before message processing ??
Any other option available??
thanks,
Nisheetahi,
Yes the basis people have shared the folder and they have mapped the sap29 folder into sap27 using I:\ drive
But the files are not getting picked....am i giving the source directory wrong??
I am giving I:\Folder_Name
suggestions needed
thanks,
Nisheeta -
Problem with Sender Adapter File Content Conversion
Hi all!
I have a question about file content conversion in sender file adapter.
I have file like:
{field1
field2
field3
field4
$
{field5
field6
field7
field8
And i need to get file like:
<dealings>
<deal>
<field1>{field1</field1>
<field2>field2</field2>
<field3>field3</field3>
<field4>field4</field4>
<field5>-}*</field5>
</deal>
<deal>
<field1>{field5</field1>
<field2>field6</field2>
<field3>field7</field3>
<field4>field8</field4>
<field5>-}*</field5>
</deal>
</dealings>
I put content conversion parameters:
deal.fieldSeparator = $
deal.fieldNames = field1,field2,field3,field4,field5
And i get a file like:
<ns:mt_swift_file>
<dealings>
<deal>
<field1>{field1</field1>
</deal>
<deal>
<field1>field2</field1>
</deal>
<deal>
<field1>field3</field1>
</deal>
<deal>
<field1>field4</field1>
</deal>
<deal>
<field1>-}*</field1>
</deal>
<deal>
<field1/>
</deal>
<deal>
<field1>{field5</field1>
</deal>
<deal>
<field1>field6</field1>
</deal>
<deal>
<field1>field7</field1>
</deal>
<deal>
<field1>field8</field1>
</deal>
<deal>
<field1>-}*</field1>
</deal>
</dealings>
</ns:mt_swift_file>
What i do wrong?
As i understand, XI put string to a separate tag after symbol 'nl', but how can i get structure without unnecessary tags?Hi,
Check some links for FCC
Introduction to simple(File-XI-File)scenario and complete walk through for starters(Part1)
Introduction to simple (File-XI-File)scenario and complete walk through for starters(Part2)
File Receiver with Content Conversion
Content Conversion (Pattern/Random content in input file)
NAB the TAB (File Adapter)
Introduction to simple(File-XI-File)scenario and complete walk through for starters(Part1)
Introduction to simple (File-XI-File)scenario and complete walk through for starters(Part2)
How to send a flat file with various field lengths and variable substructures to XI 3.0
Content Conversion (Pattern/Random content in input file)
NAB the TAB (File Adapter)
File Content Conversion for Unequal Number of Columns
Content Conversion ( The Key Field Problem )
The specified item was not found.
File Receiver with Content Conversion
http://help.sap.com/saphelp_nw04/helpdata/en/d2/bab440c97f3716e10000000a155106/content.htm
Regards,
Phani -
Problem with Sender File Content conversion
Hi everybody,
I have a flat file with the following structure:
PR1xxxx
CL1.1xxx
ALxxx
PTxxx
PTxxx
PTxxx
CL1.2xxx
ALxxx
PTxxx
PTxxx
Cl1.3xxx
PR2xxx
CL2.1
Alxxx
PTxxx
Ptxxx
CL2.2xxx
ALxxx
PR3xxx
I need to send an IDOC (ORDERS05) per CL and I also need that the PR goes together with the CL.
Something like that:
IDOC 1
PR1xxx
CL1.1xxx
ALxxx
PTxxx
PTxxx
PTxxx
IDOC 2
PR1xxx
CL1.2xxx
ALxxx
PTxxx
PTxxx
IODC 3
PR2xxx
CL2.1xxx
The problem is that I am not able to attach the PR with each CL because the PR is written once at the beginning.
I have tested all the posibilities in the content conversion area but I don`t find the way to achiveve that.
Maybe, Have I to do something in the mapping program?
Nested substructures are possible in the File Content Conversion?
Any idea?
Thanks for everythingWe can handle this in mapping as follows
Crate an Intermediate structure Identical to your input structure. Just you need to add an sub element (Lets say "T" to your CL node.
This sub element will be used to remember CL node belongs to which PR node.
Map your Input structure to Intermediate structure.
While mapping PR Node of input to PR Node of Intermediate structure use a user defined function as follows
Integer ii;
GlobalContainer g;
g=container.getGlobalContainer();
Object o= g.getParameter("_&HLID");
if (o==null) ii=new Integer(0);
else
ii =(Integer)o;
ii =new Integer(ii.intValue()+1);
g.setParameter("_&HLID",ii);
Use another user defined function to retrieve the value of this _&HLID and put it to T as follows:
GlobalContainer g;
g=container.getGlobalContainer();
Object o= g.getParameter("_&HLID");return o.toString();
For all other fields just do a 1:1 mapping.
Then
Map your intermediate structure to destination structure (IDOC)
Here the only catch is:
For populating the value of PR for each CL
Pass both the element T and the element of PR from which you want to pick the value to a user-defined function (raise the context of both elements to the top node).
In array a we have the value of T
In array b we have the value of element of PR
int j=0;
for(int k=0;k<b.length;k++){
for (int i=0;i<a.length;i++)
if (a<i>.equals(new Integer(j+1).toString())){
System.out.println(b[j]);
j=j+1;
Hope this takes care of your problem.
If you don't get anything please get back to me.
Abinash -
File Content Conversion in Sender File
how to convert a fixed length flat file without end seperator sent to XI to a xml form?
Pleasegive me the idea of Sender Adapter configuration details (esp endSeperator)Hi,
For file content convertion if there are fixed lenth then no need to give the feildseperator,just give the fixed lenths for all the feild in FCC.
check below links for FCC
/people/venkat.donela/blog/2005/03/02/introduction-to-simplefile-xi-filescenario-and-complete-walk-through-for-starterspart1
/people/venkat.donela/blog/2005/03/03/introduction-to-simple-file-xi-filescenario-and-complete-walk-through-for-starterspart2
/people/arpit.seth/blog/2005/06/02/file-receiver-with-content-conversion
/people/anish.abraham2/blog/2005/06/08/content-conversion-patternrandom-content-in-input-file
/people/shabarish.vijayakumar/blog/2005/08/17/nab-the-tab-file-adapter
/people/venkat.donela/blog/2005/03/02/introduction-to-simplefile-xi-filescenario-and-complete-walk-through-for-starterspart1
/people/venkat.donela/blog/2005/03/03/introduction-to-simple-file-xi-filescenario-and-complete-walk-through-for-starterspart2
/people/venkat.donela/blog/2005/06/08/how-to-send-a-flat-file-with-various-field-lengths-and-variable-substructures-to-xi-30
/people/anish.abraham2/blog/2005/06/08/content-conversion-patternrandom-content-in-input-file
/people/shabarish.vijayakumar/blog/2005/08/17/nab-the-tab-file-adapter
/people/jeyakumar.muthu2/blog/2005/11/29/file-content-conversion-for-unequal-number-of-columns
/people/shabarish.vijayakumar/blog/2006/02/27/content-conversion-the-key-field-problem
/people/michal.krawczyk2/blog/2004/12/15/how-to-send-a-flat-file-with-fixed-lengths-to-xi-30-using-a-central-file-adapter
/people/arpit.seth/blog/2005/06/02/file-receiver-with-content-conversion
http://help.sap.com/saphelp_nw04/helpdata/en/d2/bab440c97f3716e10000000a155106/content.htm
Regards,
Phani.
Reward Points If Helpful -
File Sender adapter with File content conversion
Hi
I'm having problems picking up a flat file that has some junk characters in the file.
I'm usign a file sender adapter with file content conversion. The adapters shows the following error-
Conversion of complete file content of to XML format failed around position 0: sun.io.MalformedInputException
this is the sample data with junk char's -
A20099201009999009999060815160505051700130008151vÿÿÿÿ³ r 0OK0476 31N016227241915840IV 00840 ÿÿÿ ÿ ÿÿÿÿÿÿÿÿ ÿ ÿÿÿ
There is not much in the file content conversion. This is a fixed length file, I'm just pickign it up & passing it to an inbound proxy. All my processing is in the proxy.
I'd appreciate any suggestions.
Thanks
RachanaHi Rachana,
Do you use a specific "encoding" like UTF-8 or ISO-8859-1 in your Sender CC?
To be simple, Encoding is linked to country, you can find all "iso-nnnn" via google or some of them in sap help.
http://help.sap.com/saphelp_nw2004s/helpdata/en/e3/94007075cae04f930cc4c034e411e1/content.htm
Moreover, with your source file opened thanks to Notepad (for instance), use option "save UNDER", you will the encoding use by your file
Mickael
Maybe you are looking for
-
Images do not display unless renamed.
We are currently running Oracle Fusion Middleware 11GR2 with webcache enabled. Our applications are using forms 11GR2. We have an image jar file that contains the application icon images we use in our applications. When we bring up the application
-
Hi All, I would like to connect the database and retrieve and updates values from/into tables through swing components.I have tried that,but some socketexception is occured. please answer to my question. Regards, Aravind
-
HI all, Is there a table to find out the 'date format' of the users in BW/ BI? Regards, Adarsh
-
XMP data issue with mixed up audio
I have a lot of xdcam (+similar) footage in a rather large project. We move the project around a fair bit to different systems/editors etc. A couple of times we have had audio in some of the footage all muddled up. Not in sync at all, in fact as if a
-
Feature Request - Fonts to Curves
Apart from the UI issues of Acrobat DC, one feature I would like to see added is a button that converts fonts to curves. The watermark / flattener preview method is unacceptable and clunky in 2015.