Greenplum Database 管理员指南 6.2.1..................... - 149 - 创建和管理视图 .............................................................................................................. - 150 - 创建视图 .................................... ...................... - 150 - 删除视图 .................................................................................................................. - 150 - 创建视图的最佳实践 ............................. ............................. - 151 - 视图的依赖关系 ...................................................................................................... - 152 - 视图是如何被存储的 ...............................0 码力 | 416 页 | 6.08 MB | 1 年前3
Pivotal Greenplum 最佳实践分享Reorganize代替、或者使用AO表; 系统表不支持Reorganize操作,因此,需要定期vacuum,例如设置定时作业,每周对所有系统表vacuum analyze一次 • 查询视图GP_TOOLKIT.GP_BLOAT_DIAG可监控垃圾空间的膨胀系数 • REINDEX:回收索引的垃圾空间 AGE监控和管理 PostgreSQL的MV xid_stop_limit: 1000000000, AGE大于10亿停止工作,等待vacuum执行 数据库对象数上限的最佳实践 GPDB内部的对象:所有的表(包括分区表)、索引、视图等都称为对象 GPDB最佳实践所推荐的对象管理要求是:一个数据库内对象不要超过10 0000个 最佳实践是出于对系统性能和稳定性因素建议对pg_class 所维护的对象数进行约束 500GB?根据实际情况调整 – gp_workfile_limit_per_query 本参数为4.2.8以上版本增加,防止临时空间SPILL档数过多导致空间急剧增长 视图gp_workfile_usage_per_query可以实时监控每个query正在使用的临时空间大小 注:在GP4.3中内置了这个view,在GP4.2中需要执行./share/postg0 码力 | 41 页 | 1.42 MB | 1 年前3
Greenplum数据仓库UDW - UCloud中立云计算服务商Workbench/J是⼀个独⽴于DBMS,跨平台的SQL查询分析⼯具。具有通⽤性好、⼩巧、免安装等优点, 并且功能强⼤,查询编辑器⽀持⾃动补全,Database Explorer可以查看和编辑各种数据库对象(表、视图、存储过程等)。 详情可⻅:SQL Workbench/J 访问 udw 访问UDW数据仓库 Greenplum数据仓库 UDW Copyright © 2012-2021 UCloud 优刻得 PARTITION beijing VALUES ('BG'), DEFAULT PARTITION other ); 6.2查看分区表信息 查看分区表信息 通过 pg_partitions 视图,您可以查看分区表设计信息。下⾯⽰例可以查看 p_store_sales 表的分区设计信息: SELECT partitionboundary, partitiontablename, partitionname 执⾏来⾃⽂件的命令 \o [⽂件名] 向⽂件或者 |管道 发送所有查询结果 5. 信息选项 \d [名字] 描述表, 索引, 序列, 或者视图 \d{t|i|s|v|S} [模式] (加 "+" 获取更多信息) 列出表/索引/序列/视图/系统表 \da [模式] 列出聚集函数 \db [模式] 列出表空间 (加 "+" 获取更多的信息) \dc [模式] 列出编码转换0 码力 | 206 页 | 5.35 MB | 1 年前3
Greenplum 精粹文集们制作了一个简单的表格,用 ID 识别行、SSN 识别个人且包含个人 提供的评分及其评分的日期。 在用户(gpuser)希望访问包括加密的 SSN 的完整数据的时候,他们 可以使用视图 v_sample_ssn,这是 sample_ssn_parts 表的一个简单视图,包含应 用于 SSN 字段的功能。该功能使用 gpuser 身份向 ESA 发出请求以访 问策略并获得密匙。它应用于策略和数据密匙上,并将解密适当的数 据以便用户进行查看。 ###-##-6789 这样的显示内容,这依据于 ESA 上创建且下推 到本地 PEP 流程的策略。 当你每次输入查询码的时候,添加这些功能会有点麻烦,而且你可能 会希望限制用户对基础数据表的访问。如果创建一个视图自动应用功 能的话就方便得多。 CREATEVIEW v_sample_ssn_parts AS SELECT id,pty_varcharsel(ssn,'ssn') as ssn, rating 现在任何人都可以输入如下的查询信息: SELECTid, ssn, rating, rating_date FROM v_sample_ssn_parts WHERE id = 1 自动应用该功能,而且大多数用户都会访问此视图。接下来,我们需 要能够更轻松地插入、更新和删除数据。最理想的是应用的功能尽可 能实现透明化,通过对表格创建 INSERT、UPDATE 和 DELETE(插入、 更新和删除)可以实现这点。 CREATEOR0 码力 | 64 页 | 2.73 MB | 1 年前3
完全兼容欧拉开源操作系统的 HTAP 数据平台 Greenplum调度算法保障在线业务对 CPU 的实时抢占及抖 动抑制,创新业务优先级 00M 内存回收算法保障在线业务安全可靠运行。 • 新文件系统 EulerFS:面向非易失性内存的新文件系统,采用软更新、目录双视图等技术减少文件元数据同步 时间,提升文件读写性能。 • 内存分级扩展 etMem:新增用户态 swap 功能,策略配置淘汰的冷内存交换到用户态存储,用户无感知,性能 优于内核态 swap。0 码力 | 17 页 | 2.04 MB | 1 年前3
Greenplum数据库架构分析及5.x新功能分享3A Segment 3B Segment 3C Segment 3D Segment 1A Segment 1B Segment 1C Segment 1D Segment 2A Segment 2B Segment 2C Segment 2D Segment 3A Segment 3B Segment 3C Segment 3D Segment 1A Segment 1B Segment 1C 1C Segment 1D Segment 2A Segment 2B Segment 2C Segment 2D Segment 3A Segment 3B Segment 3C Segment 3D 分布和分区 SELECT COUNT(*) FROM orders WHERE order_date >= ‘Oct 20 2007’ AND order_date < ‘Oct 27 2007’ 1C Segment 1D Segment 2A Segment 2B Segment 2C Segment 2D Segment 3A Segment 3B Segment 3C Segment 3D 10 Pivotal Confidential–Inter nal Use Only 多级分区存储 • 哈希Distribution:数据均 匀的分布到各个数据节点 • 范围分区: 数据节点内部,0 码力 | 44 页 | 8.35 MB | 1 年前3
Greenplum 6: 混合负载的理想数据平台Segment 1D Segment 2A Segment 2B Segment 2D Segment 3A Segment 3B Segment 2C Segment 3C Segment 3D 分区 SELECT COUNT(*) FROM orders WHERE order_date >= ‘Oct 1 2007’ AND order_date <= ‘Oct 31 2007’ 1C Segment 1D Segment 2A Segment 2B Segment 2C Segment 2D Segment 3A Segment 3B Segment 3C Segment 3D 15 Pivotal Confidential–Internal Use Only 递归查询 表‘SALES’ 表‘SALES’ ■ 层次结构 ■ 树状结构 WITH RECURSIVE 3C Segment 3D 直接分发 SELECT * FROM orders WHERE id = 1; Segment 1A Segment 1B Segment 1C Segment 1D Segment 2A Segment 2B Segment 2C Segment 2D Segment 3A Segment 3B Segment 3C Segment 3D UPDATE orders0 码力 | 52 页 | 4.48 MB | 1 年前3
VMware Greenplum v6.18 Documentation5 and install PostGIS 2.5.4. Note: The PostGIS topology extension postgis_topology and the PostGIS 3D and geoprocessing extension postgis_sfcgal are not supported by Greenplum PostGIS and are not included 'POLYGON((0 0 0,0 5 0,5 5 0,5 0 0,0 0 0))', '3D Square'); INSERT INTO geom_test ( gid, geom, name ) VALUES ( 2, 'LINESTRING(1 1 1,5 5 5,7 7 5)', '3D Line' ); INSERT INTO geom_test ( gid, geom, name does not support the following features: The PostGIS topology extension postgis_topology The PostGIS 3D and geoprocessing extension postgis_sfcgal A small number of user defined functions and aggregates0 码力 | 1959 页 | 19.73 MB | 1 年前3
VMware Greenplum v6.19 Documentation5 and install PostGIS 2.5.4. Note: The PostGIS topology extension postgis_topology and the PostGIS 3D and geoprocessing extension postgis_sfcgal are not supported by Greenplum PostGIS and are not included 'POLYGON((0 0 0,0 5 0,5 5 0,5 0 0,0 0 0))', '3D Square'); INSERT INTO geom_test ( gid, geom, name ) VALUES ( 2, 'LINESTRING(1 1 1,5 5 5,7 7 5)', '3D Line' ); INSERT INTO geom_test ( gid, geom, name does not support the following features: The PostGIS topology extension postgis_topology The PostGIS 3D and geoprocessing extension postgis_sfcgal A small number of user defined functions and aggregates0 码力 | 1972 页 | 20.05 MB | 1 年前3
VMware Greenplum v6.17 Documentation5 and install PostGIS 2.5.4. Note: The PostGIS topology extension postgis_topology and the PostGIS 3D and geoprocessing extension postgis_sfcgal are not supported by Greenplum PostGIS and are not included 'POLYGON((0 0 0,0 5 0,5 5 0,5 0 0,0 0 0))', '3D Square'); INSERT INTO geom_test ( gid, geom, name ) VALUES ( 2, 'LINESTRING(1 1 1,5 5 5,7 7 5)', '3D Line' ); INSERT INTO geom_test ( gid, geom, name does not support the following features: The PostGIS topology extension postgis_topology The PostGIS 3D and geoprocessing extension postgis_sfcgal A small number of user defined functions and aggregates0 码力 | 1893 页 | 17.62 MB | 1 年前3
共 18 条
- 1
- 2













