Generation Process of new part encoding and generation process of part Encoding

Source: Internet
Author: User

Generation Process of new part encoding and generation process of part Encoding
1. Background 1.1 region-level code

In the system, we divide the region-level codes into: district, street, community, and cell ).

The numbers they correspond to are:

Area: 2;

Sub-District: 3;

Community: 4;

Unit grid: 5

1.2 tcregion table and vcregion table

The tcregion table contains information about all regions.

Vcregion table

This table is a visual Chart Based on the tcregion table. The creation code is as follows:

 

The following table is obtained after creation. Observe this table to see the internal relationships between street code, Community code, and grid code.

 

2. Obtain the parameters required for the new part encoding.

To obtain the encoding of the new part, two parameters are required: subTypeID and cellName. SubTypeID is obtained:

 

CellName is a grid Code. Its obtaining method is usually to obtain XY when the mark is located, which is obtained through the geographic server or directly querying the database. The following is a cellName.

 

3. Flowchart

 

 

4. Detailed explanation of the encoding format

 

 

QDM: the last six digits of the Code in the cell grid.

Unicode: indicates the part encoding of the corresponding part identified by subTypeID. the last four digits are used.

MaxCode (+ |-) 1: Adds or drops the maximum encoding in the part layer by sorting rules.

 

5. Detailed Coding Process

This process has been written out using the stored procedure. You can query dlsys. fcGetPhyLayerNewObjCode. Here is a step-by-step explanation of the process in this stored procedure.

5.1 obtain QDM

Suppose cellName = '123 '.

 

If no data is found, replace it with the first six digits of cellName, that is, 410302.

 

5.2 obtain the unified part encoding and part layer name.

Assume that the detected SubTypeID is 514.

 

Or to obtain the uniqueCode, the last four digits are required:

 

5.3 obtain maxCODE

QDM, uniqueCode, and phylayerName (gas well covers) have been obtained from 4.1 and 4.2 ).

Query the existing largest encoding in the table dlgis. Gas manhole cover. After the query, compare it with the data combined by QDM and uniqueCode according to the rule to obtain the maximum value.

 

Here we get:

 

5.4 obtain encoding sorting rules

The encoding may be an increment rule or a decrease rule. The rules are configured here:

 

5.5 get new Encoding

 

Add or subtract 1 from maxCode.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.