---
title: "Summer reading tip: the SQL:2023 spec"
publication: "Postgres Weekly"
issue: 509
published_at: "2023-06-07"
canonical_url: "https://postgresweekly.com/issues/509"
---

Plus a Postgres stream taking place in a few hours, . |        

#​509 — June 7, 2023 

[Web Version](https://postgresweekly.com/issues/509)  

Together with [![Crunchydata\](https://res.cloudinary.com/cpress/image/upload/c_fill,g_auto,w_430,h_100/e_make_transparent/co_white,e_outline:7/xyflkz7n00elwtgja9ne.png)](https://www.crunchydata.com/products/crunchy-bridge?utm_source=cppg-prim-0607)   

Postgres Weekly 

[![\](https://res.cloudinary.com/cpress/image/upload/w_1280,e_sharpen:60,q_auto/ietlsmbvnjgcc7ih2bjp.jpg)](https://www.crunchydata.com/blog/high-compression-metrics-stograge-with-postgres-hyperloglog)  

[High-Compression Metrics Storage with Hyperloglog](https://www.crunchydata.com/blog/high-compression-metrics-stograge-with-postgres-hyperloglog) — [postgresql-hll](https://github.com/citusdata/postgresql-hll) is an extension introducing the [HyperLogLog algorithm](https://en.wikipedia.org/wiki/HyperLogLog) to Postgres. HyperLogLog is a probabilistic algorithm to efficiently estimate the number of distinct values in large datasets, trading a little precision for noteworthy time and memory savings. 

Christopher Winslett   

[What is a Postgres 'Schema'](https://www.cybertec-postgresql.com/en/what-is-a-schema-in-postgresql/) — The term _schema_ has multiple meanings in the database world, but in Postgres schemas are named containers that can contain other named objects like tables, data types, and functions, somewhat akin to a namespace. 

Hans-Jürgen Schönig   [![\](https://copm.s3.amazonaws.com/34ffa2f3.png)](https://www.crunchydata.com/products/crunchy-bridge?utm_source=cppg-prim-0607) 

[❤️ Postgres](https://www.crunchydata.com/products/crunchy-bridge?utm_source=cppg-prim-0607) — You need a database provider that loves Postgres as much as you do. We'll take care of all the hassle - monitoring, backups, HA, disaster recovery so you don't have to. Want amazing support? We'll be there when you have questions. 

Crunchy Bridge sponsor   

[A Guide to PgBouncer/Postgres Compatibility](https://jpcamara.com/2023/05/25/a-comprehensive-guide.html) — [PgBouncer](https://www.pgbouncer.org/) is a popular connection pooler but [not every Postgres feature works with it.](https://jpcamara.com/2023/04/12/pgbouncer-is-useful.html) If you’re trying to debug PgBouncer issues, this is for you and this post tries to make it easier to navigate [the more extensive writeup.](https://jpcamara.com/2023/04/12/pgbouncer-is-useful.html) 

JP Camara   

**IN BRIEF:** 

- Standards organization ISO has published the latest SQL spec: [SQL:2023](https://www.iso.org/standard/76584.html). With _the core section alone_ clocking in at 1715 pages and ~$200, it's sure to be a sleeper hit. We refer to Peter Eisentraut's recent [round up of what's new in SQL:2023](https://peter.eisentraut.org/blog/2023/04/04/sql-2023-is-finished-here-is-whats-new) and the [status of SQL:2023 features in Postgres](https://peter.eisentraut.org/blog/2023/04/18/postgresql-and-sql-2023) if you want to dig deeper _without_ nodding off.
- Instaclustr's Sharan Foga is the [PostgreSQL Person of the Week.](https://postgresql.life/post/sharan_foga/) Relatively new to Postgres, she's excited to engage with the community 👋
- 📅 If you're reading this issue in time, there's a live [▶️ The Future of the Postgres Ecosystem](https://www.youtube.com/watch?v=yrX-SIF46Us) roundtable discussion taking place _today_ at 10am Pacific (1pm ET, 6pm BST, 7pm CEST), just a few hours after we send this issue. Folks from Yugabyte, NeonDB, CoreDB, Google, PGEdge, and others will be present.   

[An SQL Recipe: Comparing with Neighbors](https://antonz.org/sql-compare-neighbors/) — If you need to calculate the difference between records and the previous or next ones, the `LAG()` window function is for you. Anton gives us some examples of its use. _(If you missed our interview with him about window functions last week, it’s at the bottom of [issue 508.](https://postgresweekly.com/issues/508))_ 

Anton Zhiyanov   

[The Future of OpenAI for Postgres on Azure](https://techcommunity.microsoft.com/t5/azure-database-for-postgresql/openai-chatgpt-retrieval-plugin-and-postgresql-on-azure/ba-p/3826411) — ChatGPT supports plugins as a way to provide the popular chatbot / LLM with data to formulate replies. This post explains the broad concepts and shows how a combination of plugins and storing embeddings with pgvector could open up new querying opportunities. 

Krishnakumar Ravi (Microsoft)   

▶[Why Giving Talks at Postgres Conferences Matters](https://www.youtube.com/watch?v=RIvG_2ErRlU) — With Alvaro Herrera and Boriss Mejias. 
Citus Data   

[Postgres Roles and Privileges Explained](https://www.aviator.co/blog/postgresql-roles-and-privileges-explained/) 
Masaya Suzuki    

Code and Tools 

[![\](https://res.cloudinary.com/cpress/image/upload/w_1280,e_sharpen:60,q_auto/weyfqukne4wztlryxab2.jpg)](https://github.com/schemaspy/schemaspy)   

[SchemaSpy: Database Documentation Built Easily](https://github.com/schemaspy/schemaspy) — A long-standing tool that analyzes your database’s metadata, schema, and other information to help you visualize, check, and understand your data model via an HTML report. 

SchemaSpy   

[[Open Source\] Columnar, Vectorized Postgres](https://github.com/hydradatabase/hydra) 

HYDRA sponsor   

[pgsql-ast-parser 11.1: A Simple Postgres SQL Parser](https://github.com/oguimbal/pgsql-ast-parser) — A TypeScript-based SQL syntax parser that can produce a typed AST for most queries (PL/pgSQL isn't supported). It’s used as part of the author’s [pg-mem project](https://github.com/oguimbal/pg-mem), a mini, in-memory Postgres clone for Node and the browser. 

Olivier Guimbal   

[Goxygen 0.4: Go Backend Generator for JavaScript Projects](https://github.com/Shpota/goxygen) — A tool that sets up a new Go-based project with Angular, React, or Vue in the front-end, and Docker and Docker Compose files to make it all work. Supports Postgres, MySQL or MongoDB as the database. 

Sasha Shpota   

📧 Do we have a Go newsletter too? [We do.](https://golangweekly.com/)  

- [FerretDB 1.3](https://github.com/FerretDB/FerretDB)
 ↳ MongoDB alternative with Postgres under the hood.
- [DBeaver 23.1](https://github.com/dbeaver/dbeaver/releases/tag/23.1.0)
 ↳ Popular cross-platform database IDE.
- [Skunk 0.6](https://typelevel.org/skunk/)
 ↳ Postgres client for Scala developers.
- [PostgresML 2.5.1](https://github.com/postgresml/postgresml/releases/tag/v2.5.1)
 ↳ Machine learning in SQL.
- [pgAdmin 4 v7.2](https://www.postgresql.org/about/news/pgadmin-4-v72-released-2647/)    

**Got a new email?** You can [change your address here](https://postgresweekly.com/edit_subscription/*|UID|*). 

--- 

**Bored of us?** [Click here to stop getting Postgres Weekly](https://postgresweekly.com/leave/*|UID|*). 

--- 

**Got a link for us?** Reply and tell us. We can't include everything but we'll look at anything you send. _Thanks!_ 

--- 

Published by Cooper Press Ltd.
Fairfield Enterprise Centre, Louth, LN11 0LS, United Kingdom 

Postgres, PostgreSQL and the Slonik Logo are trademarks or registered trademarks of the PostgreSQL Community Association of Canada. 

[Stop getting this newsletter](https://postgresweekly.com/leave/*|UID|*).
