cancel
Showing results for 
Search instead for 
Did you mean: 

Error in highly complicated FCC scenario

harish_babu5
Participant
0 Kudos

Hi guys,

I am doing an IDoc to File structure

Receiver FCC is a complex structure

this is the struture:

Segment1

Segment2

     Segment7

     Segment3

          Segment8

          Segment4

     Segment5

Segment6

The client wants the output as a string without any field separators.

Initially I configured with "FieldFixedLengths", I got this error "field length not matching".

Segment two has close to fifty fields

I am using space as field separator and it's taken care of in mapping.

For ex: the seventh field of segment two has forty characters, but only ten characters value is populated. I will the remaing twenty nine fields with spaces and add the space mentioned in the FCC settings of CC

Eighth field has three characters, ninth has nine, and tenth has 2. These fields get respective values with sufficient length, so I am concatanating without spaces.

Everything is coming fine but when seven and eight fields are missing in segment two, the eighth field is shifted one position ahead.

How to take care of this? Does FCC actually support this nested structure?

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Harish,

You are saying that a field is shifting to different position. Are you mapping the missing fields with mapwithdefault function? Try it once.

Regards,

Suhale Shaik.

harish_babu5
Participant
0 Kudos

One of he fields I am using

Field seven of segment two. It can either have value or no value

If there is no value send thirty nine spaces and the FCC add one more space and it meets the requirement of 40 characters

If there is value, then we count the number of characters in field and accordingly padd spaces with udf

If we have ten charcaters we padd 29 spaces and if we have four characters we padd 35 spaces.

Field 8, 9 and ten are always concatanated

At times when the field seven doesn't come in the structure we are getting only 39 spaces in the output.

This is the errror we are facing.

FCC is not adding the space when field is not there in source data

Field separator is "0x20"

Former Member
0 Kudos

why don't you try with if else condition in mapping with that field exists try with 39 spaces if it doesn't exist try with 40 spaces.

Regards,

Suhale Shaik.

harish_babu5
Participant
0 Kudos

Without udf it's not posible as the number of characters tht come in the field are dynamic. It could be any number from 1 to 40 or it may not come at all

Former Member
0 Kudos

Do like this Hari

Field--->Exists--->if--->then--->field value with length with spaces--->target field

                                     Else--->send 40 Spaces------>Target field.

Tell me whether this one works or not.

Regards,

Suhale Shaik.

pvishnuvardan_reddy
Active Contributor
0 Kudos

Hi Harish,

The limitation of FCC is up to 3 level hierarchy.

Can you check the below blogs:

Still if you are having the issues, then can you please share us the screen shots for better understanding of the issue.

Regards

Vishnu