design-postgis-tables
仓库创建 2025年7月24日最近提交 1 个月前SkillHot 收录 20 天前
▸ 精选理由
覆盖几何类型、坐标系与空间索引,是位置应用建表实战参考
这个 Skill 做什么
提供完整的 PostGIS 空间表设计建议与性能模式
把地理数据在 PostgreSQL/PostGIS 里怎么建表讲清楚:选对 geometry 类型、坐标系(CRS)、空间索引和分区策略。适合做地图、半径/框选检索、最近邻或大规模地理分析时使用。重点是根据查询模式优化索引和坐标单位,能显著提高空间查询性能并降低存储成本。
▸ 展开 SKILL.md 英文原文
Comprehensive PostGIS spatial table design reference covering geometry types, coordinate systems, spatial indexing, and performance patterns for location-based applications
1.8k
Stars
99
Forks
10
仓库内 Skill
+13
7 日增星
安装 / 使用
给你的 Agent 一句话(通用)
帮我安装这个 skill:https://raw.githubusercontent.com/timescale/pg-aiguide/main/skills/design-postgis-tables/SKILL.md或 curl 直取 SKILL.md
curl -fsSL "https://raw.githubusercontent.com/timescale/pg-aiguide/main/skills/design-postgis-tables/SKILL.md"SKILL.MD 节选查看完整文件 ↗
# PostGIS Spatial Table Design ## Before You Start (5 Questions) 1. What is the geographic scope (single city/region vs global)? 2. What are your primary query patterns (within-radius, bbox, intersects, nearest-neighbor)? 3. What units do you need for distance/area (meters vs CRS units), and how accurate must they be? 4. What is the expected scale (rows, write rate), and is the data mostly append-only? 5. Do you need 3D (Z) or measures (M), or is 2D enough? **SQL injection note:** When turning these patterns into application code, use parameterized queries for user-provided values (WKT/WKB, coordinates, IDs, radii). Avoid string-concatenating untrusted input into SQL; for dynamic identifi
via SKILL·HOT · 数据来自 GitHub 公开信息 · 原文版权归作者所有