Skip to Content
author's profile photo Former Member
Former Member

DI : How do I use an existing batch???! Important!


I know i already posted this topic but im posting it again. And i'll post it again afterwards until someone arrives on this forum that knows the answer.

When adding a GoodIssue to SAP through the SAP DI,

I need to be able tu use an existing batchnumber so that the client knows where the product came from.

<b>Delphi Code:</b> (even if you dont program delphi you still get the idea)

<i>oGoodIssue.Lines.AccountCode := '_0000000000012';

oGoodIssue.Lines.ItemCode := 'A00001';

oGoodIssue.Lines.Quantity := 10;

oGoodIssue.Lines.Price := 5.5;

oGoodIssue.Lines.BatchNumbers.BatchNumber := 'Btch#4';

oGoodIssue.Lines.BatchNumbers.Quantity := 5;

intRetVal := oGoodIssue.Add;

if intRetVal <> 0 then


oCompany.GetLastError(intErr, StrErr);

strErrMsg := strErr;

booErreur := True;


So if im adding a GoodIssue and "Btch#4" doesnt exist,

SDK will create it, no prob.

But what i need is that Btch#4 DOES exist and I need GoodIssue to ascociate this GoodIssue with it.

So that i know that with "Batch#4" there was <b>25 that came IN</b>

and <b>10 that went OUT</b>

But when i specify a Batch number that exist there is a key violation... cause he try to create the batch insted of using it.

Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Mar 24, 2004 at 12:12 PM

    Hi Denis

    We had lots of batch problems programming an AddOn for SBO 6.20.36. In SDK DI 6.20.36 there is no batch object at all. So we had to work directli onto the database tables.

    We found three tables concerning batches:

    OSRD: Keeps all good receipts/deliveries for goods requiering batch management as long as they are just moved into/out of your warehouse, but haven't still got their batch number.

    OIBT: Master table for all batches; keeps batch balance too.

    IBT1: Table of batch transactions.

    Perhaps you could solve your problem by changing that tables in the following way:

    > Add a new line to IBT1

    > Correct the balance in OIBT

    > Correct balance and status in OSRD

    I fear that SAP doesn't like that way of changing their tables - but if SAP doesn't help us, we just have to help ourselves...

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.