最近几年来,地理信息系统无论是在理论上还是应用上都处在一个飞速发展的阶段。 GIS被应用于多个领域的建模和决策支持,如城市管理、区划、环境整治等等,地理信息成为信息时代重要的组成部分之一; “数字地球”概念的提出,更进一步推动了作为其技术支撑的GIS的发展。 与此同时,一些学者致力于相关的理论研究,如空间感知、空间数据误差、空间关系的形式化等等。 这恰好说明了地理信息系统作为应用技术和学科的两个方面,并且这两个方面构成了相互促进的发展过程。
The PostgreSQL schema (SCHEMA) can look like a collection of tables.
A schema can contain views, indexes, data types, functions, operators, and so on.
The same object name can be used in different schemas without conflicts; for example, both schema1 and myschema can contain a table named mytable.
Advantages of using patterns:
Allow multiple users to use a database without interfering with each other.
Organize database objects into logical groups for easier management.
Objects applied by third parties can be placed in separate schemas so that they do not conflict with the names of other objects.
Patterns are similar to directories at the operating system layer, but patterns cannot be nested. We can use it. CREATE SCHEMA Statement to create a pattern, the syntax format is as follows: Next we connect to runoobdb to create the schema myschema: The output “CREATE SCHEMA” indicates that the schema was created successfully. Next let’s create another table: The above command creates an empty table, and we use the following SQL to see if the table is created: Delete an empty schema (where all objects have been deleted): Delete a schema and all objects contained in it: 5.12.1. Grammar ¶
CREATE SCHEMA myschema.mytable ( ... );
5.12.2. Example ¶
runoobdb=# create schema myschema; CREATE SCHEMA
runoobdb=# create table myschema.company( ID INT NOT NULL, NAME VARCHAR (20) NOT NULL, AGE INT NOT NULL, ADDRESS CHAR (25), SALARY DECIMAL (18, 2), PRIMARY KEY (ID) );
runoobdb=# select * from myschema.company; id | name | age | address | salary ----+------+-----+---------+-------- (0 rows)
5.12.3. Delete Mod ¶
DROP SCHEMA myschema;
DROP SCHEMA myschema CASCADE;