Database Design of WEBGIS System


The system uses PostgreSQL as the attribute database, PostGIS as the spatial database, and implements data persistence through the Hibernate
framework .

System equipment model design

1. Device model structure

The urban underground power pipeline equipment model is shown in the figure.
insert image description here

It consists of three parts: electrical equipment, civil engineering equipment and logical relations. Electrical equipment is a general term for the various nodes and lines through which electrical energy is distributed from substations to end users, including containers, cable sections, and distribution lines. A distribution line is a logical device that provides an electrical path from the origin of distribution to the end of distribution. Distribution lines are the basis for managing the logical relationship of all electrical equipment, including all containers and cable segments that pass through the electrical path. The container is the node equipment of the power grid, including substations, branch boxes, switch stations, ring main units, branch joints, and transformers. Civil engineering equipment is the urban infrastructure that carries electrical equipment, and the power pipe network is built on its basis. Civil engineering equipment includes underground and above-ground point buildings such as wells and towers, as well as pipe trench sections, pipe trench lines and urban roads. The logical relationship is used to describe the relationship between system devices, which we summarize into three kinds of relationship: connection relationship, bearer relationship and containment relationship.

2. Equipment logical relationship model

The logical relationship model of system equipment is shown in Figure 7.3 2, where containers, cable sections, substations, urban roads, trench sections, and point buildings are physical equipment, and distribution lines and trench lines are logical equipment. The logical relationship model is divided into the association relationship between electrical equipment, the association relationship between civil engineering equipment, and the association relationship between electrical equipment and civil engineering equipment. The starting point of the distribution line is the substation, the container and the cable segment are connected, and the connection of multiple cable segments and containers constitutes the distribution line. Urban roads carry the trench lines formed by trench sections and point-shaped buildings, and the construction of civil engineering equipment is based on roads. The cable section is laid in the underground trench section or the virtual trench section formed by pole towers on the ground, and the trench section is the basis for carrying electrical lines.
insert image description here

System Property Database Design

1. System properties database

The system attribute database provides data support for system equipment description, business graph attributes, and logical relationships between equipment.
We divide the attribute database into electrical part, civil engineering part, business map entity part and system auxiliary entity part. The PostgreSQL database selected by
the system is an object-relational database management system, which not only supports the relational data model
, but also supports the object-oriented data model.
According to the system requirements, the project team designed the system attribute database using the object-oriented data model , and the list of entities is shown in the table

insert image description here

2. Entity inheritance relationship


The PostgreS QL database implements the mechanism of table inheritance. Through the table inheritance mechanism, users can refer to the records of this table and all its descendant tables when using queries on a table . Using this mechanism, we uniformly inherit all entity tables in the attribute database
from the object base table. The sub-table describes the same attributes of the entity through the fields in the object base table, and at the same time adds
sub-table fields that describe their different attributes. The inheritance relationship of the attribute database entities is shown in the figure. insert image description here
The table structure of the object base table is shown in the table.
insert image description here

The electrical equipment entity table, civil engineering entity table, business graph entity table and system auxiliary entity table are uniformly inherited from the object base table, through which the system can uniformly query all attribute data and manage the same fields in the attribute table. At the same time, the project team uses the multi-layer inheritance mechanism to inherit the equipment with the same function from the same parent table through the power pipeline equipment model, and realizes the hierarchical management of the attribute database. Electrical point equipment such as branch boxes, ring network cabinets, transformers, substations, and switch stations are inherited from the parent table of containers; cable segments and cable segments represent the underground and above-ground parts of distribution lines respectively and are inherited from the parent table of cable segments; civil engineering points Shaped equipment such as wells and towers inherit from the parent table of point-shaped equipment; underground pipe sections such as direct burial, tunnels, pipes, trenches, and bridge frames, and virtual pipe sections on the ground are uniformly inherited from the parent table of pipe sections.
3. Attribute database model diagram
The relationship between the entity tables in the attribute database is shown in the figure.
insert image description here

The following describes the relationship between the attribute database entity tables.

1) Electrical physical part

(1) The substation and the distribution line form a one-to-many connection through the starting station;
(2) The distribution line forms a one-to-many connection with the cable section and its sub-meter through the distribution line;
(3) The cable section and the container The class entity table forms a one-to-one relationship through the start container and the end container.

2) Solid part of civil engineering

(1) The road and the trench line form a one-to-many connection through the road;
(2) The trench line and the trench section and its sub-table form a one-to-many connection through the trench line;
(3) The trench section and the point A one-to-one connection is formed between the shape buildings through the starting point civil work and the end point civil work.

3) Contact with other entities

(1) The entity table of the cable section and the trench section forms a many-to-many relationship through the trench section passed by the cable section; (
2) The section entity table forms a many-to-one relationship with the trench line through the trench line;
(3 ) Tube holes and brackets form a many-to-one relationship with the section entity table through the section number.

Guess you like

Origin blog.csdn.net/leva345/article/details/131370376
Recommended