cancel
Showing results for 
Search instead for 
Did you mean: 

Key Field Value for File Adapter Sender Wildcard

aayushaggarwal
Participant
0 Kudos

Hi Experts,

My scenario is that i have a comma seperated .CSV file, converting it to xml format using the file content conversion (FCC).

The problem is the value of key field is not fixed,

Example: i have a key field Invoice and initially it's value is A, i got 3 records with the same key value and in the 4th record the value is changed to B.

Invoice,Field1,Field2,Field3

A,12,12,12

A,13,13,13

A,14,14,14

B,11,11,11

B,21,21,21

C,13,13,13

So, in the result i require one Recordset for value 'A' and one for 'B' and similarly for other key values.

Can i put something in the keyFieldValue like a wildcard with the help of which PI can recognize the changed value and create a new Recordset.

This is a very urgent. Waiting for you replies....

Regards,

Aayush Aggarwal

Accepted Solutions (1)

Accepted Solutions (1)

nitindeshpande
Active Contributor
0 Kudos

Hi Aayush,

My suggestion would be read each record as separate recordset and then in mapping using Node function Split by value - Value Changed, you can have the required recordset in single context.

In FCC you can use this -

Recordset Structure - Transaction,*

Transaction.fieldNames - field1,field2,field3,field4

Transaction.fieldSeparator - 'nl'



Regards,

Nitin Deshpande

aayushaggarwal
Participant
0 Kudos

Hi Nitin,

Yes exactly, we have used the same approach, it's under process currently.

Let's see if that works....

Regards,

Aayush

Answers (1)

Answers (1)

engswee
Active Contributor
0 Kudos

Hi Aayush

From your sample above, the lines all contain similar structure. If that is the case, you don't need to configure key field value as there is just 1 recordset structure. You can additional configure an offset to ignore the first line.

Rgds

Eng Swee

aayushaggarwal
Participant
0 Kudos

Hi Eng,

Can you please elaborate what actually you are suggesting....

Regards,

Aayush