Home | 簡體中文 | 繁體中文 | 雜文 | 打賞(Donations) | ITEYE 博客 | OSChina 博客 | Facebook | Linkedin | 知乎專欄 | Search | About

部分 V. PostgreSQL

目錄

48. PostgreSQL 安裝
48.1. Ubuntu 12.04.1 LTS 安裝
48.2. YUM 預設源安裝
48.3. PostgreSQL 官方 YUM 源安裝
48.3.1. 9.2
48.3.2. 9.3
48.3.3. 9.4
48.3.4. 9.6
48.3.5. PostgreSQL 10
48.4. PostgreSQL 配置
48.4.1. postgresql.conf
48.4.2. pg_hba.conf
48.5. 創建dba用戶
49. PostgreSQL 命令
49.1. psql - PostgreSQL interactive terminal
50. Database Administration
50.1. User Account Management
50.1.1. Create User
50.1.2. Drop User
50.1.3. Rename User
50.1.4. SET PASSWORD
50.2. Access Privilege System
50.2.1. SHOW GRANTS
50.2.2. show privileges
50.2.3. Grant privileges
50.2.4. Revoke privileges
50.2.5. Show Privileges
50.2.6. MAX_QUERIES_PER_HOUR/MAX_UPDATES_PER_HOUR
50.2.7. Table Privileges
50.2.8. Column Privileges
50.3. Maintenance 資料庫維護
50.3.1. CHECK 檢查表
50.3.2. ANALYZE 分析表
50.3.3. CHECKSUM
50.3.4. OPTIMIZE 優化表
50.3.5. REPAIR 修復
50.4. INFORMATION_SCHEMA
50.4.1. 查詢表欄位
50.5. Backup and Recovery
50.5.1. Import / Export
50.5.1.1. Export(Backup)
50.5.1.2. Import(Recovery)
50.5.1.3. xml
50.5.1.4. 備份表數據
50.5.1.5. source
50.5.1.6. 使用 mysqlhotcopy 備份 MyISAM 引擎的資料庫
50.5.1.7. AutoMySQLBackup
50.5.1.8. xtrabackup - Open source backup tool for InnoDB and XtraDB.
50.5.1.8.1. Percona yum Repository
50.5.1.8.2. Creating an Incremental Backup
50.5.2. Snapshot Backup
50.5.2.1. LVM Snapshot
50.5.2.2. Btrfs Snapshot
51. DDL - Data Definition Language
51.1. 資料庫管理(Database)
51.1.1. create
51.1.2. drop
51.1.3. Alter
51.1.4. Rename
51.1.5. CHARACTER
51.1.6. show create database
51.2. 表管理(Table)
51.2.1. 數據類型
51.2.1.1. SET 集合類型
51.2.2. create table ... select
51.2.3. modifiy table
51.2.4. TEMPORARY Table
51.2.5. Collate
51.2.6. CHARACTER
51.2.7. DEFAULT
51.2.7.1. AUTO_INCREMENT
51.2.7.2. 表存儲位置(DATA DIRECTORY)
51.2.8. KEY
51.2.8.1. PRIMARY KEY
51.2.9. COMMENT
51.2.10. Engine 存儲引擎
51.2.10.1. 顯示當前資料庫支持引擎
51.2.10.2. 切換引擎
51.2.10.3. FEDERATED
51.2.10.4. BLACKHOLE
51.2.10.5. ARCHIVE
51.2.10.6. CSV
51.3. Partitioning
51.3.1. RANGE
51.3.2. LIST
51.3.3. HASH
51.3.3.1. LINEAR HASH
51.3.4. KEY分區
51.3.5. Subpartitioning
51.3.6. 分區管理
51.3.6.1. 新增分區
51.3.6.2. 刪除分區
51.3.6.3. 重建分區
51.3.6.4. 分區維護
51.3.7. EXPLAIN PARTITIONS
51.3.8. SHOW CREATE TABLE
51.3.9. INFORMATION_SCHEMA.partitions 表
51.3.10. 分區數據操作
51.4. Index
51.4.1. SHOW INDEX
51.4.2. CREATE INDEX
51.4.3. DROP INDEX
51.4.4. rebuild
51.5. 外鍵(Foreign Key)
51.5.1. FOREIGN KEY (RESTRICT)
51.6. 視圖(View)
51.7. 存儲過程(PROCEDURE)
51.7.1. 存儲程序
51.7.2. 函數
51.8. 觸發器(Trigger)
51.8.1. create trigger
51.8.1.1. Update 更新出發
51.8.1.2. Delete 刪除出發
51.8.1.3. Insert 插入出發
51.8.2. drop trigger
51.8.3. show triggers
51.8.4. EXAMPLE
51.8.4.1. BEFORE/AFTER
51.8.4.2. UUID
51.8.4.3. CALL PROCEDURE
51.9. 事件調度器(EVENT)
51.9.1. 啟用 EVENT
51.9.2. 創建 EVENT
51.9.3. 禁用/啟用
51.9.4. show events
52. DML (Data Manipulation Language)
52.1. INSERT
52.1.1. INSERT INTO ... SELECT
52.1.2. INSERT IGNORE
52.1.3. INSERT...ON DUPLICATE KEY UPDATE
52.2. REPLACE
52.3. DELETE
52.3.1. 刪除重複數據
53. SQL Statement Syntax
53.1. DISTINCT
53.2. group by
53.3. HAVING
53.4. REGEXP
53.5. IN / NOT IN
53.6. ALL / Any
53.7. exists, not exists
53.8. UNION
53.8.1. UNION ALL
53.9. OUTFILE/LOAD DATA INFILE
53.9.1. Export data to CSV from MySQL
53.9.2. Import data from CSV file.
53.10. CASE Syntax
53.11. MySQL 專有命令
53.11.1. SQL_NO_CACHE
53.11.2. SIGNAL Syntax
53.12. SQL 92
54. Functions and Operators
54.1. COUNT
54.2. group_concat() 列傳行
54.3. UUID()
54.4. String
54.4.1. LEFT/RIGHT
54.4.2. RPAD/LPAD
54.4.3. CONCAT
54.4.4. CONCAT_WS
54.4.5. 連結所有欄位
54.4.6. GROUP_CONCAT
54.4.7. replace
54.4.8. SUBSTRING
54.4.9. SUBSTRING_INDEX
54.4.10. AES_ENCRYPT / AES_DECRYPT
54.5. Date and Time
54.5.1. year/month/day hour:minite:second
54.5.2. Unix time
54.5.3. DATE_FORMAT
54.5.4. DATE_SUB/DATE_ADD
54.5.4.1. DATE_ADD
54.5.5. datediff / timediff
54.6. 數值函數
54.6.1. cast 類型轉換
54.6.2. truncate 保留小數位數
54.6.3. MOD 求余
54.7. Control Flow Functions
55. PostgreSQL GUI
55.1. pgAdmin III
55.2. phpPgAdmin
55.3. Monitoring
55.3.1. PgBadger
55.4. pgModeler - PostgreSQL Database Modeler
56. Barman Backup & recovery for PostgreSQL
57. pgbouncer - lightweight connection pooler for PostgreSQL
57.1. 安裝 pgbouncer
57.1.1. Ubuntu
57.1.2. CentOS
57.2. 配置 pgbouncer
58. Foreign data wrappers
59. Barman for PostgreSQL
60. Connector
60.1. Pomm
61. Replication
61.1. Bucardo
62. FAQ
62.1. Reset root password 重置MySQL root密碼
62.2. 資料庫內容替換
62.3. 查看錯誤代碼
62.3.1. ERROR 1153 (08S01) at line 3168: Got a packet bigger than 'max_allowed_packet' bytes
62.3.2. ERROR 1129 (00000): Host 'XXXXXX' is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts'
62.4. 臨時表是否需要建索引
62.5. Kill 腳本
62.6. ERROR 1503 (HY000): A PRIMARY KEY must include all columns in the table's partitioning function
62.7. ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executing this statement.
62.8. ERROR 1819 (HY000): Your password does not satisfy the current policy requirements
62.9. 重新整理AUTO_INCREMENT欄位
62.10. 轉換 latin1 到 UTF-8
62.11. this is incompatible with sql_mode=only_full_group_by
62.12. [Warning] Changed limits: max_open_files: 5000 (requested 20480)
62.13. ERROR 1364: 1364: Field 'id' doesn't have a default value

PostgreSQL 實用實例參考