PowerView Refresh Options
Staging Tables Overview
Staging tables are used in PowerViews for version 6.x of EnergyCAP and in EnergyCAP Online 1.6 and greater. Staging tables summarize meter data at all higher levels of the hierarchy - buildings, organizations, etc., enhancing the speed at which this information is displayed in the EnergyCAP application. The data contained in the Group Manager is also based on the data contained in the staging tables. Staging tables are updated through the following mechanisms.
Methods to update the Staging Tables
- Login to EnergyCAP. Click on Tools > Options Global. Click on the Settings tab. Check the box next to "Update Powerviews" and set a time for it to update. When this checkbox is selected, the staging tables will be updated every X hours depending on the users setting. When any user logs into EnergyCAP, the software will check to see when the staging tables were last updated. It will compare that date and time to the setting that is in the settings tab (ie every X hours). If it has been more than X hours since the staging tables have been updated, the database will begin to update the staging tables. Again, this is ONLY triggered by a user login. This method IS NOT RECOMMENDED for users with large (greater than 700mb) databases. These users should use option #2.
- A DBA (Database Administrator) can schedule a task on the SQL Server to execute the three stored procedures involved with updating the staging tables. These procedures must be executed in the following order:
- CB2
- generateBillSummaryTables
- generateGHGSummaryTables
The DBS should evaluate how long these take to complete and schedule accordingly to fit in with other maintenance tasks such as backup. - Finally, a user with Administrator permissions (ie permissions to use the Administrator.exe located in the EnergyCAP installation folder) can manually execute each of these stored procedures in order. When logged into Administrator, go to Stored Procedures > Save/Execute. Then select CB2 from the Execute Existing Procedure list and click OK. When the procedure finishes, a popup message will appear indicating the procedure has completed. Repeat the procedure for the generateBillSummaryTables procedure and then finally for the generateGHGSummaryTables procedure. When finished, the staging tables will be refreshed.

