EdgeDB combines the simplicity of a NoSQL database with relational model’s powerful querying, strictness, consistency, and performance.
|EdgeDB||NoSQL document DB||Relational Database|
|Low entry barrier||+||+||–|
|Efficient and Advanced Queries||+||–||+|
|Data Consistency Guarantees||+||varies||+|
|Built-in schema migration||+||–||–|
|GraphQL & data frameworks||+||–||–|
EdgeDB is designed to support modern and emerging approaches to building highly reactive and flexible applications.
Thanks to its elegant data model and expressive query language, EdgeDB greatly simplifies working with complex application data.
EdgeQL is the default language of EdgeDB. Conceptually it is a superset of GraphQL, which is supported directly as well.
EdgeQL supports fetching object hierarchies with arbitrary level of nesting, filtering, sorting, aggregation, window functions, and recursion.
EdgeDB supports a high-performance protocol for language bindings, as well as a straightforward REST API.
In EdgeDB, schema structure and metadata are accessible in queries, and are intelligently reflected in language bindings.
This enables rich metaprogramming capabilities, greatly assisting in building user interfaces.
EdgeDB treats data schema changes as a version control issue. Changes automatically generate formal diffs.
The integrity of schema state is thoroughly validated, and revisions are signed with a cryptographic hash.
EdgeDB is built on top of PostgreSQL, inheriting all its core strengths: ACID compliance, performance, tooling, and reliability.
abstract type Text: # This is an abstract object containing # text. required property body -> str: # Maximum length of text is 10000 # characters. constraint max_len(10000) type User extending Named # Named is a standard abstract base # type, that provides a name link. abstract type Owned: # By default links are optional. required link owner -> User type Status extending Dictionary # Dictionary is a subtype of Named from # the standard library that enforces name # uniqueness across all instances of its # subtype. type Priority extending Dictionary type LogEntry extending Owned, Text: # LogEntry is an Owned and a Text, # so it will have all of their links # and properties, in particular, the # "owner" link and the "body" property. required property spent_time -> int64 scalar type issue_num_t extending sequence # issue_num_t is defined as a concrete # sequence type, used to generate # sequential issue numbers. type Comment extending Text, Owned: required link issue -> Issue link parent -> Comment
type Issue extending Named, Owned, Text: required property number -> issue_num_t: readonly := true # The number values are automatically # generated, and are not supposed to be # directly writable. property time_estimate -> int64 property start_date -> datetime: default := SELECT datetime_current() # The default value of start_date will be a # result of the EdgeQL expression above. property due_date -> datetime required link status -> Status link priority -> Priority multi link watchers -> User # The watchers link is mapped to User # type in many-to-many relation. multi link time_spent_log -> LogEntry: constraint exclusive # Exclusive multi-link represents # a one-to-many relation. multi link related_to -> Issue