2014 Aug 21 3:49 PM
Hi,
We have modified the ranges for a company code Directly in a the table NRIV, but while doing so we have mistaken ly missed the leading zeros for FROM and TO numbers as a result When we post a Document Using FB01 it saved in the table as without out leading Zeros (eg - BKPF-BELNR), so when we tried to display the document using FB03 it says Document does not exists. Please suggest a solution to revert the document or update the values in all Database tables. I have given a Example below.
In NRIV table we have updated the range as 12345678 instead of 0012345678.
So when posting in FB01 the document numbers are stored as 87654321 instead of 0087654321.
This is causing issues in all standard T-code where we give Doc No as not created.
Please help me ASAP.
Thanks,
Arun
Hi,
We have modified the ranges for a company code Directly in a the table NRIV, but while doing so we have mistaken ly missed the leading zeros for FROM and TO numbers as a result When we post a Document Using FB01 it saved in the table as without out leading Zeros (eg - BKPF-BELNR), so when we tried to display the document using FB03 it says Document does not exists. Please suggest a solution to revert the document or update the values in all Database tables. I have given a Example below.
In NRIV table we have updated the range as 12345678 instead of 0012345678.
So when posting in FB01 the document numbers are stored as 87654321 instead of 0087654321.
This is causing issues in all standard T-code where we give Doc No as not created.
Please help me ASAP.
Thanks,
Arun
2014 Aug 21 4:10 PM
Try changing the conversion routine attached to belnr, with a condition for the transaction code
2014 Aug 21 4:17 PM
Hi
We have corrected the changes in number range now the problem is how to reverse or correct the values of the Document posted.
Thanks,
Arun
2014 Aug 21 4:21 PM
Hi
You need to change the range in NRIV table in order to place the leading zero, and then you should correct all posted documents.
To correct the document is not easy because it means:
- Find out all wrong posted documents (i.e all tables with data about those documents, like BKPF, BSEG,.........)
- Delete the wrong record and insert it again but with right number
Max
2014 Aug 21 4:43 PM
Hi,
We have corrected the NRIV for ranges but for documents there will be lots of tables which will contain the document number and its not advisable to update standard tables right?
Thanks
2014 Aug 21 4:46 PM
Not advisable at all, instead if possible cancel all the postings.and post the documents again.
2014 Aug 21 6:05 PM
Yes
of course
but if it need you can do it or you can try
The document number is a key, so you can only to delete the wrong record and insert it again
Some account documents like CO, profit center.... can be regenerated by standard report
Another solution (suggested by kartik sharma) can be to delete and post them again: the archiving is only standard way I know to delete a documen, and I don't know if it's possibile to archive single documents.
Sincerly I don't know which is the easier solution
but if the documents are posted by FB01 probably the table are not so much you believe
Max
2014 Aug 21 8:58 PM
It's not an ABAP question. As correctly pointed out, document number is a key field and there are many ties to that, so the only option would be to reverse the documents via SAP transactions (this depends on the type of the document).
Also since this looks like a major screw-up, you might want to seek help from SAP, maybe they have some magical solution or at least a word of wisdom.
I wouldn't advise trying to fix this by making direct updates in the database, as one might be tempted. You'll break more than you'll fix.