A graph-relational database with declarative schema, built-in migration system, and a next-generation query language
 
 
 
Go to file
Aron Adler 8493825a7a
Fix minor TypeScript syntax error in docs (#5378)
2023-04-24 15:37:57 -04:00
.github CI: Fix tests on different versions of Postgres (#5117) 2023-03-22 12:23:02 -05:00
dev-notes Add a checklist for adding new types to EdgeDB (#4373) 2022-09-16 18:07:32 -07:00
docs Fix minor TypeScript syntax error in docs (#5378) 2023-04-24 15:37:57 -04:00
edb Forbid ranges of user-defined scalars (#5345) 2023-04-22 15:58:10 +02:00
postgres@e4c4e6258c Bump Postgres to 14.7 and fix non-transactional errors 2023-02-13 18:53:08 -05:00
tests Forbid ranges of user-defined scalars (#5345) 2023-04-22 15:58:10 +02:00
.editorconfig Run test workflow in shards (#2217) 2021-02-12 15:42:00 -06:00
.flake8 Upgrade our python linters (#4977) 2023-02-02 17:42:47 -08:00
.gitignore Docs reorg (#3039) 2021-11-10 17:27:39 -05:00
.gitmodules Parse SQL with libpg_query and translate to our pgsql.ast (#4480) 2022-10-13 20:57:53 +02:00
.mailmap Add mailmap 2019-08-22 15:54:08 -04:00
CODE_OF_CONDUCT.md Add CoC. 2019-05-13 13:05:33 -04:00
CONTRIBUTING.rst Add documentation contributing guidelines (#4761) 2022-12-05 12:11:35 -08:00
Cargo.lock Replace `twoway` with `memchr` 2023-03-13 18:38:35 +02:00
Cargo.toml Initial GraphQL rewrite implementation (#1299) 2020-03-30 15:54:37 +03:00
LICENSE Put EdgeDB under the Apache License v2.0 2018-05-09 22:11:25 -04:00
MANIFEST.in Switch to Rust CLI by default (#1303) 2020-03-29 10:02:19 -07:00
Makefile Adapt setup.py/pyproject.toml to setuptools 54 (#4261) 2022-08-19 15:10:25 -07:00
NOTICE Add the NOTICE file 2019-10-17 17:04:11 -04:00
README.md Add syntax highlighting (#4878) 2023-03-17 08:14:23 -04:00
build_backend.py Adapt setup.py/pyproject.toml to setuptools 54 (#4261) 2022-08-19 15:10:25 -07:00
logo.svg Add README 2018-05-10 12:33:56 -04:00
pyproject.toml Type descriptor parsing cleanups (#5361) 2023-04-17 10:48:51 -07:00
setup.py Unbreak prod builds (again) (#5286) 2023-03-31 11:40:31 -07:00

README.md

EdgeDB

Stars license discord

Quickstart   •   Website   •   Docs   •   Playground   •   Blog   •   Discord   •   Twitter



What is EdgeDB?

EdgeDB is a new kind of database
that takes the best parts of
relational databases, graph
databases, and ORMs. We call it
a graph-relational database.



🧩 Types, not tables 🧩


Schema is the foundation of your application. It should be something you can read, write, and understand.

Forget foreign keys; tabular data modeling is a relic of an older age, and it isn't compatible with modern languages. Instead, EdgeDB thinks about schema the same way you do: as object types containing properties connected by links.

type Person {
  required property name -> str;
}

type Movie {
  required property title -> str;
  multi link actors -> Person;
}

This example is intentionally simple, but EdgeDB supports everything you'd expect from your database: a strict type system, indexes, constraints, computed properties, stored procedures...the list goes on. Plus it gives you some shiny new features too: link properties, schema mixins, and best-in-class JSON support. Read the schema docs for details.


🌳 Objects, not rows 🌳


EdgeDB's super-powered query language EdgeQL is designed as a ground-up redesign of SQL. EdgeQL queries produce rich, structured objects, not flat lists of rows. Deeply fetching related objects is painless...bye, bye, JOINs.

select Movie {
  title,
  actors: {
    name
  }
}
filter .title = "The Matrix"

EdgeQL queries are also composable; you can use one EdgeQL query as an expression inside another. This property makes things like subqueries and nested mutations a breeze.

insert Movie {
  title := "The Matrix Resurrections",
  actors := (
    select Person
    filter .name in {
      'Keanu Reeves',
      'Carrie-Anne Moss',
      'Laurence Fishburne'
    }
  )
}

There's a lot more to EdgeQL: a comprehensive standard library, computed properties, polymorphic queries, with blocks, transactions, and much more. Read the EdgeQL docs for the full picture.


🦋 More than a mapper 🦋


While EdgeDB solves the same problems as ORM libraries, it's so much more. It's a full-fledged database with a powerful and elegant query language, a migrations system, a suite of client libraries in different languages, a command line tool, and—coming soon—a cloud hosting platform. The goal is to rethink every aspect of how developers model, migrate, manage, and query their database.

Here's a taste-test of EdgeDB's next-level developer experience: you can install our CLI, spin up an instance, and open an interactive EdgeQL shell with just three commands.

$ curl --proto '=https' --tlsv1.2 -sSf https://sh.edgedb.com | sh
$ edgedb project init
$ edgedb
edgedb> select "Hello world!"

Windows users: use this Powershell command to install the CLI.

PS> iwr https://ps1.edgedb.com -useb | iex

Get started

To start learning about EdgeDB, check out the following resources:

  • The quickstart. If you're just starting out, the 10-minute quickstart guide is the fastest way to get up and running.
  • The interactive tutorial. For a structured deep-dive into the EdgeQL query language, try the web-based tutorial— no need to install anything.
  • The e-book. For the most comprehensive walkthrough of EdgeDB concepts, check out our illustrated e-book Easy EdgeDB. It's designed to walk a total beginner through EdgeDB in its entirety, from the basics through advanced concepts.
  • The docs. Jump straight into the docs for schema modeling or EdgeQL!

Contributing

PRs are always welcome! To get started, follow this guide to build EdgeDB from source on your local machine.

File an issue 👉
Start a Discussion 👉
Join the discord 👉


License

The code in this repository is developed and distributed under the Apache 2.0 license. See LICENSE for details.