The default configurations are set up to use SQL Server date query syntax. A copy set up for Oracle is also provided.
If you database differs, please adjust the date queries in the ReportingAreasFilter to match your database. The SQL used in the expressions are based on a File GDB since the scripts exports the data for processing to a temporary File GDB.
The report configuration files have been preconfigured to use leak survey schema provided in the leak survey solutions.
If you data schema differs, additional configuration is needed before running the reports for your utility.
The steps below require you to edit JSON text files. It is recommended you edit the JSON config file in a editor that recognizes JSON formatting or use an online JSON editor.
Leak survey assignments asset counts
The leak survey assignment schema include the footage of mains and number of services within the area.
To update these fields, the UpdateAssetCountsAssignments.py script is provided.
To configure the script, complete the following steps:
- In Windows Explorer, browse to Application > ReportTools > configs folder.
- Open the AssetCountLeakSurveyAssignments.json configuration file and update the following parameters. Each parameter should point to the appropriate layer in your geodatabase.
The database name and owner are required as part of the layer name in the configuration.
Parameter |
Description |
ReportingAreas |
The reporting areas will be your leak survey assignments layer. |
SchemaGDB |
The Enterprise GDB that the ReportingArea layer resides in. |
ResultsGDB |
The Enterprise GDB that the ReportingArea layer resides in. |
Data > pipes |
The gas mains layer. |
Data > services |
The gas services layer. |
Reports > ReportingAreasFilter
| The default filter is set up to only update surveys not completed and due in 90 days. You can update all assignments by removing this parameter. |
Reports > ReportResultSchema
| The leak survey grid assignment layer, since the report is updating the reporting areas (leak survey assignments)
footage of mains and number of services fields. |
Reports > ReportResult
| The leak survey grid assignment layer, since the report is updating the reporting areas (leak survey assignments) footage of mains and number of services fields. |
- Run UpdateAssetCountsAssignments script.
Overview areas asset counts
The reporting overview schema includes the footage of mains and the number of services fields for each assignment area. These fields can be updated by running the UpdateAssetCountsOverview.py script.
To configure the script, complete the following steps:
- In Windows Explorer, browse to Application > ReportTools > configs folder.
- Open the AssetCountDistrict.json, AssetCountSubDistrict.json and the AssetCountServiceArea.json configuration files
and update the following parameters.
Parameter |
Description |
ReportingAreas |
The reporting areas will be your service area, district or subdistrict layer.
|
SchemaGDB |
The Enterprise GDB that the ReportingArea layer resides in. |
ResultsGDB |
The Enterprise GDB that the ReportingArea layer resides in. |
Data > pipes |
The gas mains layer. |
Data > services |
The gas services layer. |
Reports > ReportResultSchema
| Since the report is updated the existing data, this parameter needs to be the full name of the service area, district or subdistrict layer. |
Reports > ReportResult
| Since the report is updated the existing data, this parameter needs to be the full name of the service area, district or subdistrict layer. |
- Run UpdateAssetCountsOverview script.
Overview areas survey reports
The overview areas schemas include fields to record the count of each survey type by due date interval.
To update these fields, the UpdateLeakOverview.py script is provided.
To configure the script, complete the following steps:
- In Windows Explorer, browse to Application > ReportTools > configs folder.
- Open the LeakReportDistrict.json, LeakReportSubDistrict.json and the LeakReportServiceArea.json configuration files
Parameter |
Description |
ReportingAreas |
The reporting areas will be your service area, district or subdistrict layer.
|
SchemaGDB |
The Enterprise GDB that the ReportingArea layer resides in. |
ResultsGDB |
The Enterprise GDB that the ReportingArea layer resides in. |
Data > LeakSurveyGrids |
The leak survey assignment areas layer |
Data > Leaks |
The reported gas leaks layer |
Reports > ReportResultSchema
| Since the report is updated the existing data, this parameter needs to be the full name of the service area, district or subdistrict layer. |
Reports > ReportResult
| Since the report is updated the existing data, this parameter needs to be the full name of the service area, district or subdistrict layer. |
- Run UpdateLeakOverview script.