Skip to content

Latest commit

History

231 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

PostgreSQL's Public schema common Library (pg_PubLib) version 1

Set of PostgreSQL funcions distributed by CC0 License. Plese cite this git by its canonical URL, http://git.addressforall.org/pg_pubLib

PubLib is an effort to reduce the impact of the "historic rationale" used by PostgreSQL developer team, like the lack of overloads in some native functions, as the round() function, or the lack of orthogonality in overloads and casts. PubLib is also a Library of Snippets, implementating small and frequently used functions. Typical "small function" are also IMMUTABLE ones.

Usage recomendation

Your project not need to copy all source-code of this git. Select only the SQL files (group of functions) that your project need, maintaining it updated to be compatible with newer ones. If this git is updated, you can update also your subset of selected functions.

All other projects, in the same database or same "ecosystem", will use the same function names and same git reference for updates.

Lib Organization

Functions are grouped in thematic source-files to maintainability. Most of the thematic groups comes from PostgreSQL Documentation's "Chapter 9. Functions and Operators". Others are inspired in "snippet classes".

Function groupLabelsInspiration / dependence
(System) Administration (srcadminpg/docs/functions-admin) / string.
Aggregate (srcagg, aggregatepg/docs/functions-aggregate) / array, json, sring.
Array (src)arraypg/docs/functions-array (no dependency).
GeoJSON (src)geoJSONPostGIS/GeoJSON / pgis, json, admin.
JSON (src)json, jsonbpg/docs/functions-json / array.
PostGIS (src)st, postGisPostGIS/docs / (fixed level-04 dependencies).
String (src)str, stringpg/docs/functions-string (no dependency).
HCodes (src)hcode, distrib(Hierarchical or) Natural Codes / json, array.
Geohash (src)geohash, postGisPostGIS/Geohash / hcodes, pgis.

Libs also labeled by "dependence level"; for example Array library has no dependence, is level 01; JSON depends on Array, is level 03; and GeoJSON library depends on JSON, is level 4. The installation order is the dependency level.

Installation

See docs/install.md, using make.

About

Commom library for the public schema of standard PostgreSQL installations. CC0 License

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Contributors

Languages