How to render timestamp with a timezone that is different from current?
Explains how to display PostgreSQL timestamps with a specific timezone offset, including a custom function solution.
Hubert (depesz) Lubaczewski is a PostgreSQL expert and developer sharing practical tips on database management, query optimization, and tooling. His blog covers PostgreSQL performance, CSV handling, T-SQL formatting, and real-world database workflows.
30 articles from this blog
Explains how to display PostgreSQL timestamps with a specific timezone offset, including a custom function solution.
A developer creates a simple, AI-assisted Node.js tool for automatically loading CSV files into PostgreSQL with minimal configuration.
Author details a fix for suboptimal indentation in complex SQL join conditions within the paste.depesz.com query pretty-printer.
A technical analysis measuring the performance impact of adding indexes on write operations (COPY) in PostgreSQL, showing slowdowns and size overhead.
PostgreSQL 19 introduces new ALTER TABLE commands to MERGE and SPLIT partitions, with initial single-process, locked implementations.
A technical analysis comparing PostgreSQL JSON storage options, compression methods (pglz vs. lz4), and performance optimizations.
Explains new PostgreSQL 19 features for synchronizing sequences via logical replication, including ALL SEQUENCES support and a sync worker.
Analyzes the performance and storage trade-offs of using a dedicated tsvector column versus an expression index for full-text search in PostgreSQL.
PostgreSQL 19 adds a new %S prompt variable to psql to display the current search_path, aiding users who frequently work with multiple schemas.
PostgreSQL 19 adds direct COPY TO support for partitioned tables, improving usability and performance over the previous SELECT workaround.
PostgreSQL 19 adds IGNORE NULLS/RESPECT NULLS options to window functions like LAG and FIRST_VALUE, improving data handling.
PostgreSQL 19 introduces GROUP BY ALL, a new SQL feature that automatically groups by all non-aggregate columns, simplifying queries.
Introduces vtime, a custom command-line utility for tracking and displaying elapsed time of long-running processes in real-time.
PostgreSQL 19 adds new random() functions for generating random dates and timestamps, useful for creating test data.
A technical analysis of a SQL interview question about detecting suspicious account logins from multiple countries within a short timeframe.
Explains a new PostgreSQL 19 feature that displays Memoize planner estimates in EXPLAIN output to help debug query plan choices.
Benchmarking pg_dump performance across PostgreSQL versions 10-18, revealing speed changes and regression in recent versions.
PostgreSQL 18 adds a function to retrieve detailed memory context statistics from any backend or auxiliary process for debugging memory issues.
PostgreSQL 18 introduces NOT VALID for NOT NULL constraints, allowing addition without table scans and validation with reduced locking.
PostgreSQL 18 adds modern SHA-256 and SHA-512 password hashing algorithms to the pgcrypto extension, enhancing security.