Guidelines for Modifying SAP Business One Data
SAP Business One gives you the power to customize the business flow easily. One of the easiest ways to do this is to run direct SQL statements on the SAP Business One database. We can always see Customers/Partners using several direct updates in some form of Add-Ons/TransactionNotification. However, it is not recommended to perform direct updates. Here are the top questions I get asked about modifying SAP Business One data:
Is it permitted to INSERT/UPDATE/DELETE on UDTs through SQL Scripts HANA Studio, SQL Management Studio, SDK DoQuery() method, Coding, B1if?
Direct updates are not allowed. It is ok for User Defined Tables (UDTs) of type [No Object & No Object with Auto. Increment] only.
Is it permitted to INSERT/UPDATE/DELETE on UDFs from System table through SQL Scripts HANA Studio, SQL Management Studio, SDK DoQuery() method, Coding, B1if?
No, it is not allowed for SAP Business One system tables.
Is it allowed to CREATE/ALTER/DROP in SAP Business One Database but not as UDTs?
It is not allowed to create tables in SAP Business One other than via SDK UDTs.
Below are some examples:
Is it allowed to use the following query: UPDATE OPOR SET Printed = ‘Y’ ?
Is it allowed to use the following query: UPDATE OPOR SET U_DSIC_ParentDoc = ‘1234’ ?
Is it allowed to use the following query: INSERT INTO [@DS_TESTUDT] ?
No, if UDT is registered for User Defined Object (UDO)
Yes, for UDTs of type [No Object & No Object with Auto. Increment] only.
These rules are described in the SAP Business One certification page: https://www.sap.com/documents/2020/06/f8d3172b-9b7d-0010-87a3-c30de2ffd8ff.html under the section: Modifying SAP Business One Data.
The same applies while doing all these modifications in SBO_SP_PostTransactionNotice and SBO_SP_TransactionNotification. Refer to SAP Note 1320484 for the same.
Thanks for sharing this..
Thank you for this post!