Hi,
When I post SO or PO ...
"Overflow in calculation of 2147480030 + 10000"
How can I fix it? seem that the posting is correct but still showing the message..
Thanks,
You must have orders with insane numbers of lines. I have not seen this happen before, even on orders with thousands of lines.
It feels like this is caused by a customization, since the number 2147480030 is not a 10000 increment. The least you should do is debug the problem and see what the program is trying to do when it errors out.
This error usually appears in very large journals. It is somewhat strange that this happens when a PO/SO is posted. Are there any journal lines ( for barcodes etc. from an add-on ) automatically created when posting takes place ?
All you can do in this case is to delete/post the journal lines so the line number starts at 10000 again.
If this happens frequently it is possible to decrease the line number increment from 10000 to 10 , but then you can only insert a few new lines between already existing ones since the Line Number is part of the primary key, but this shouldn't be a problem in an automatic journal.
First, you will have to run a report that renames the primary key to decrease all the line numbers in this S/N Table.
Then , to prevent this happening again the increment coding for the line number must be changed to a smaller interval.
If you are using a 3.6 or higher client/server on the financials database, you can also use BigInteger field instead of an Integer Field in the table, but then you will probably need to change the code ( integer variable ) too.
I'm using 2.6..
but I will run a report to change the SN line ( to lower #), and then modify rpt. "Post SN Journal"..
changing 10000 to 10
what do you think?
If SNLedgerEntry."Line No." is part of the primary key then a RENAME is necessary(modify the "Line No." in the first few records manually (10000,20000,30000.. to 10,20,30.. ) to prevent insert errors, then step through the table renaming all the records, otherwise if "Line No." is not part of the primary key create a second variable SNLedgerEntry2, stepping through the first one and writing the other.
something like :
SNLedgerEntry2.INIT;
SNLedgerEntry2.TRANSFERFIELDS("SN Journal Line");
SNCounter += 10; // or even 1
SNLedgerEntry2."Line No." := SNCounter;
SNLedgerEntry2."Posting Date" := WORKDATE;
SNLedgerEntry2.INSERT;
You can delete the old records afterwards by filtering on the "Line No.".
Comments
RIS Plus, LLC
But why happened when I posted SO and PO where I have to go to fix it..
directly to the code unit?...
It feels like this is caused by a customization, since the number 2147480030 is not a 10000 increment. The least you should do is debug the problem and see what the program is trying to do when it errors out.
RIS Plus, LLC
All you can do in this case is to delete/post the journal lines so the line number starts at 10000 again.
If this happens frequently it is possible to decrease the line number increment from 10000 to 10 , but then you can only insert a few new lines between already existing ones since the Line Number is part of the primary key, but this shouldn't be a problem in an automatic journal.
You right.. It is a modification, I have a SerialNumber table that the last line number is " 2147480030 " ..
Could I decrease that number...
Then , to prevent this happening again the increment coding for the line number must be changed to a smaller interval.
:roll:
RIS Plus, LLC
but I will run a report to change the SN line ( to lower #), and then modify rpt. "Post SN Journal"..
changing 10000 to 10
what do you think?
***
IF SNLedgerEntry.FIND('+') THEN
SNCounter := SNLedgerEntry."Line No." + 10000
ELSE
SNCounter := 10000;
SNLedgerEntry.INIT;
SNLedgerEntry.TRANSFERFIELDS("SN Journal Line");
SNLedgerEntry."Line No." := SNCounter;
SNLedgerEntry."Posting Date" := WORKDATE;
SNLedgerEntry.INSERT;
something like :
SNLedgerEntry2.INIT;
SNLedgerEntry2.TRANSFERFIELDS("SN Journal Line");
SNCounter += 10; // or even 1
SNLedgerEntry2."Line No." := SNCounter;
SNLedgerEntry2."Posting Date" := WORKDATE;
SNLedgerEntry2.INSERT;
You can delete the old records afterwards by filtering on the "Line No.".