Skip to content
Learn Netverks

Lesson

Step 17/36 47% through track

extensions-intro

Extensions introduction

Last reviewed May 28, 2026 Content v20260528
Track mode
sql_sandbox
Means
SQL sandbox
Reading
~1 min
Level
intermediate

This lesson

An orientation to the PostgreSQL track—core vocabulary, dialect notes, and what you will practice next.

You need a clear map of the PostgreSQL track so JSONB, extensions, and Postgres idioms do not feel like magic.

You will apply Extensions introduction in contexts like: Geospatial apps, full-text search, and vector similarity via Postgres extensions.

Copy Postgres SQL into psql, local PostgreSQL, or DB Fiddle (PostgreSQL dialect)—use \d and EXPLAIN ANALYZE where lessons show them. The in-browser lab ships later; psql is the practice path now. Also read the interview prep blocks.

After the core SQL track—when your stack standardizes on a specific database engine.

Extensions package optional features into a database—installed per database, not cluster-wide. Enable only what you need and pin versions in production.

Install an extension

CREATE EXTENSION IF NOT EXISTS citext;
CREATE EXTENSION IF NOT EXISTS pg_trgm;

CREATE TABLE users (
  id SERIAL PRIMARY KEY,
  email CITEXT NOT NULL UNIQUE
);

citext provides case-insensitive text; pg_trgm powers fuzzy search indexes.

Practice: Apply DDL in a throwaway practice database. Use \d table in psql to verify constraints and indexes.

Listing and removing

SELECT extname, extversion FROM pg_extension;
-- DROP EXTENSION pg_trgm;  -- only when unused

Managed cloud note

Providers allowlist extensions—verify availability before designing on exotic modules. PostGIS teaser appears in the wrap module.

Important interview questions and answers

  1. Q: CREATE EXTENSION scope?
    A: Per database—other databases in the cluster need their own CREATE EXTENSION.
  2. Q: Superuser requirement?
    A: Many extensions require elevated privileges—managed services expose allowed list.

Self-check

  1. How do you see installed extensions?
  2. What does citext help with?

Tip: CREATE EXTENSION is per database—repeat on each DB that needs citext or pg_trgm.

Interview prep

CREATE EXTENSION scope?

Per database, not entire cluster.

citext?

Case-insensitive text type for emails and identifiers.

Interview tip Lesson completion confidence

Can you explain this lesson in 30 seconds without reading notes?

Not saved yet.

Check yourself

Multiple choice — immediate feedback.

Discussion

Past discussion is visible to everyone. Only logged-in users can post comments and replies.

Starter discussion topics

  • CREATE EXTENSION?
  • citext when?

Sign up or log in to post comments and sync lesson progress across devices.

No discussion yet. Be the first to ask a question.

Jump