sqlc/sqlc

By sqlc

Updated 7 months ago

Generate type-safe code from SQL

Image
3

500K+

sqlc/sqlc repository overview

sqlc: A SQL Compiler

sqlc generates type-safe code from SQL. Here's how it works:

  1. You write queries in SQL.
  2. You run sqlc to generate code with type-safe interfaces to those queries.
  3. You write application code that calls the generated code.

Check out an interactive example to see it in action, and the introductory blog post for the motivation behind sqlc.

Overview

docker pull sqlc/sqlc

Run sqlc using docker run:

docker run --rm -v $(pwd):/src -w /src sqlc/sqlc generate

Run sqlc using docker run in the Command Prompt on Windows (cmd):

docker run --rm -v "%cd%:/src" -w /src sqlc/sqlc generate

Tag summary

Content type

Image

Digest

sha256:b8d1092c7

Size

38.2 MB

Last updated

7 months ago

Requires Docker Desktop 4.37.1 or later.