cancel
Showing results for 
Search instead for 
Did you mean: 

Proxy to JDBC Scenario

0 Kudos

Hi All,

My scenario is proxy to jdbc

  For ex if ecc triggered 100 records, in that 51st and 65th records having error in that case I need to insert remaining 98 records in jdbc table and send error notification to ecc system for the failed records.

is it possible with PI,if possible could please explain me the procedure.

Regards,

Praneeth

Accepted Solutions (1)

Accepted Solutions (1)

MichalKrawczyk
Active Contributor
0 Kudos

hi,

>>>For ex if ecc triggered 100 records, in that 51st and 65th records having error in that case I need to insert remaining 98 records in jdbc table and send error notification to ecc system for the failed records.

but this is not a good approach from the error handling perspective and you should not implement it like this - you either insert the whole message from ECC or nothing at all - as ECC will have to send the whole package again (correctly this time) - if you insert only some parts of the whole message

how can you send the missing parts only if ECC can only send 100 messages ?

stick to the all or none approach - it will save you lots of troubles in the future,

Regards,

Michal Krawczyk

Former Member
0 Kudos

...or switch to single message approach posting them one by one. That depends on the volume of messages you are transmitting.

0 Kudos

Hi Michal,

Agree with your approach. But still, as my client is insisting for this requirement, is there any other way (though it is a bad approach ) to achieve this requirement..?

for e.g., a sale order with 10 line items is being sent from ECC (proxy) and 5 items/records got successfully inserted at receiver jdbc side and the 6th was in error. Now we will notify ECC team to send the sale order with the particular line item (6th line item) again. Meanwhile, the message processing in rcv jdbc channel should not get stopped and the processing should start again from the 7th line item..

I couldn't figure it out how this can be achieved.. Cud u pls suggest anything on this requirement..?

Regards,

Praneeth

rajasekhar_reddy14
Active Contributor
0 Kudos

Hi Praneeth,

Develop scenario using multi mapping mechanism , this case PI genarates single message for one record and JDBC adapter also perform individual insert operation , this case any record failed it will not affect any other records processing.

if JDBC adapter throwsa error due to wrong data then records fails then implement alert mechanism to receiver an email but this error covers all errorJDBC errors so you have to differentiate this.

Now record failed at data base level say data base team found that sales order data not complete then request them to move failed records to error table.

then you can inform the same tro SAP ECC.

Regards,

Raj

Answers (3)

Answers (3)

0 Kudos

Thanks all for your valuable feedback........

baskar_gopalakrishnan2
Active Contributor
0 Kudos

As previous experts mentioned this design approach will be hard to maintain and you cannot fully automate the requirement. You can create individual message for each record and use jdbc lookup in the mapping (to check this inserting record already exists or not). If insert fails, you get the failed message as alerts mail and use them for fixing the issue at ECC for resending it again. This jdbc lookup check will help to insert only the not inserted records.Best approach is to use Stored Procedure to handle all or nothing. But in your case, that is not the requirement.

gagandeep_batra
Active Contributor
0 Kudos

Hi praneeth,

You can choose this approach .

first send the message to JDBC and add one status in that table and update if it is successful.

then read table which are not successful and send ack for that.

Regards

Gagndeep