官术网_书友最值得收藏!

PostgreSQL high-level object interaction

To sum up, a PostgreSQL server can contain many databases, programming languages, roles, and tablespaces. Each database has an owner and a default tablespace; a role can be granted permission to access or can own several databases. The settings can be used to control the behavior of the PostgreSQL server on several levels, such as database and session. Finally, a database can use several programming languages:

PostgreSQL high-level object interaction

PostgreSQL main components conceptual relations

In order to create a database, one needs to specify the owner and the encoding of the database; if the encoding of template1 does not match the required encoding, template0 should be used explicitly.

For the car web high level objects interaction portal database, let us assume that the database owner is the car_portal_role role, and encoding is UTF8. In order to create this database, one can execute the following commands:

CREATE ROLE car_portal_role LOGIN;
CREATE DATABASE car_portal ENCODING 'UTF-8' LC_COLLATE 'en_US.UTF-8' LC_CTYPE 'en_US.UTF-8' TEMPLATE template0 OWNER car_portal_app;;
主站蜘蛛池模板: 城步| 宁阳县| 鄢陵县| 巴楚县| 浮山县| 叶城县| 从江县| 西华县| 丹棱县| 清流县| 陇西县| 彩票| 荔浦县| 龙江县| 沙雅县| 胶南市| 资中县| 寿阳县| 鄢陵县| 琼海市| 和硕县| 东乌珠穆沁旗| 洞头县| 郴州市| 罗甸县| 普兰县| 夏津县| 沁阳市| 西华县| 神农架林区| 连云港市| 铜梁县| 翁源县| 高要市| 宁化县| 茌平县| 梅河口市| 朝阳县| 桦南县| 合作市| 乳山市|