{"repo":"xocolatl/periods","free":true,"listed":false,"github":"https://github.com/xocolatl/periods","clone":"git clone https://github.com/xocolatl/periods.git","description":"PERIODs and SYSTEM VERSIONING for PostgreSQL","language":"PLpgSQL","stars":320,"topics":["postgresql","periods","sql-standards","system-versioning","extension","proof-of-concept"],"license":"PostgreSQL","category":"databases-storage","readme_excerpt":"Periods and SYSTEM VERSIONING for PostgreSQL compatible 9.5–15 This extension recreates the behavior defined in SQL:2016 (originally in SQL:2011) around periods and tables with SYSTEM VERSIONING . The idea is to figure out all the rules that PostgreSQL would like to adopt (there are some details missing in the standard) and to allow earlier versions of PostgreSQL to simulate the behavior once the feature is finally integrated. What is a period? A period is a definition on a table which specifies a name and two columns. The period’s name cannot be the same as any column name of the table. Defining a period constrains the two columns such that the start column’s value must be strictly inferior to the end column’s value, and that both columns be non-null. The period’s value includes the start value but excludes the end value. A period is therefore very similar to PostgreSQL’s range types, but a bit more restricted. Since extensions cannot modify PostgreSQL’s grammar, we use functions, views, and triggers to get as close to the same thing as possible. Unique constraints Periods may be part of PRIMARY KEY s and UNIQUE constraints. The extension will create a unique constraint over all of the columns specified and the two columns of the period given. It will also create an exclusion constraint using gist to implement the WITHOUT OVERLAPS part of the constraint. The function also takes optional parameters if you already have such a constraint that you would like to use. Unique const","default_branch":null,"files":null,"tree":[],"storefront":"/r/xocolatl","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/xocolatl/periods/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}