Stored Procedures - Consolidated Processes

Top  Previous  Next

The Update process for Tailored (Custom) Stored Procedures has been changed (Version 10.1.0.1 ) to handle the update process as a consolidated process so that ALL Companies are updated at the same time whenever the AccuBuild Stored Procedure Library has been updated in a software release.  This consolidated process is necessary for AccuBuild Installations where more than one company has been set up in the AccuBuild System.

 

In addition, the update process will create an audit trail of tailored stored procedures that exist for each company for both the Global Procedures (BASEGLOB Database) that serve ALL companies as well as the individual Company Procedures (BASECOMP Database) in each company folder.  If there are multiple companies with Global Procedures, a warning will now be displayed to alert the user.

 

Best Practices for Tailored Global Procedures: It is always best to keep the global stored procedures on a single company and NOT on multiple companies in order to prevent any conflicts with the tailored solution library.  These tailored procedures are stored in the library as class number 112000.  When multiple companies have Global Procedures set up under class 112000, the stored procedures are created in the order of how the company scripts are processed which (see audit table results).  This can cause issues if two companies have the same stored procedure set up in class 112000 because the  last company to be processed will overwrite the previous company’s stored procedure.  This is why the recommended best practice is to place ALL Global stored procedures in a single company.  

 

Hint: With the UserID parameter used in Global Procedures, you can create query commands to determine which company is making the procedure call in case you need to have different sets of business rules for different companies.

 

Refer to the Audit Trail Tracking features below to review the various stored procedures that are set up for both global procedures (class 112000) and company procedures (class 113000):

 

 

StoredProcedure_CustomScriptClass112000

 

 

These procedures are updated automatically whenever changes are made in an AccuBuild Software release but can also be updated manually at any time from the AccuBuild Mobile Settings Screen by clicking on the Setup / refresh Mobile Database Procedures Button.

 

SY_ABM_Setup_RefreshMobileDatabaseProcedures

 

Audit Trail Tracking: Whenever the stored procedure libraries are updated (either automatically or manually) the system will keep track of the update process using two methods:

 

User Activity Log - Every stored procedure update will be logged in the User Activity Log and flagged as a Record Type of 1 as shown:

 

StoredProcedure_UserActivityLog

 

Disk Files - In addition to the User Activity Log, two text files will be created in the AccuBuild Data Folder for both tailored solution classes:

 

oGLOBAL - ALLCompanyCustomStoredProcedureUpdateAuditTrail_Class_112000.txt

oCOMPANY - ALLCompanyCustomStoredProcedureUpdateAuditTrail_Class_113000.txt