Meet TypeDB and TypeQL

TypeDB is a strongly typed database with an intelligent reasoning engine to infer new data and a declarative query language based on composable patterns to find it easily.

The benefits of strong typing

TypeDB brings the benefits of strong typing in modern programming languages to the database, allowing developers to use abstraction, inheritance and polymorphism when modeling and querying data – and finally removing the mismatch between logical and physical data models.

  1. 1
  2. 2
  3. 3
  4. 4
  5. 5
  6. 6
  7. 7
  8. 8
  9. 9
  10. 10
  11. 11
  12. 12
  13. 13
  14. 14
  15. 15
  16. 16
  17. 17
  18. 18
  19. 19
  20. 20
  21. 21
  22. 22
  23. 23

define

# entities
employee sub entity, 
   owns full-name, 
   owns email,
   plays group-membership:member;

business-unit sub entity, 
   owns name, 
   plays group-membership:group;

# relations
group-membership sub relation,
   relates group, 
   relates member;

# attributes
full-name sub attribute, value string;
name sub attribute, value string;
email sub attribute, value string;
slider

Model data naturally – as the entities, relations and attributes defined in an entity-relationship diagram. There's no need for separate logical and physical data models due to database limitations and operational optimizations (e.g., normalization). In TypeDB, the logical data model is the physical data model.

Learn More

The ease of pattern matching

TypeQL is a fully declarative query language based on pattern matching. There is no need for developers to tell TypeDB what to do (e.g., joins). Rather, they use patterns to describe what they're looking for. And because patterns are composable, they can be reused and combined to create new queries.

  1. 1
  2. 2
  3. 3
  4. 4
  5. 5
  6. 6
  7. 7
  8. 8
  9. 9
  10. 10
  11. 11
  12. 12
  13. 13
  14. 14
  15. 15
  16. 16
  17. 17
  18. 18
  19. 19
  20. 20
  21. 21
  22. 22
  23. 23

# no need to union employee + contractor
# or join user to employee|contractor
match $u isa user;

# no need to recursively traverse a hierarchy of groups
match
   $u isa user;
   $ug isa user-group;
   $gm (group: $ug, member: $u) isa group-membership;

# no need to specify how permissions are granted
match
   $u isa user;
   $p (subject: $u) isa permission;

Just describe what you are looking for, and TypeDB will find it. You never have to influence how queries are executed, let alone explicitly tell the database what to do. TypeDB’s query language, TypeQL, is designed specifically for expressing what data looks like, not how to get it. There are no joins, no unions and no need for ordered query logic.

Learn More

The power of inference

TypeDB's built-in reasoning engine, a technology previously found only in knowledge-based systems, enables it to infer data on the fly by applying logical rules to existing data – and in turn, allows developers to query highly interconnected data without having to specify where or how to make the connections.

  1. 1
  2. 2
  3. 3
  4. 4
  5. 5
  6. 6
  7. 7
  8. 8
  9. 9
  10. 10
  11. 11
  12. 12
  13. 13
  14. 14
  15. 15
  16. 16
  17. 17
  18. 18
  19. 19
  20. 20
  21. 21
  22. 22
  23. 23

match $e isa employee, has full-name $fn, has salary $sa;

match $c isa contractor, has full-name $fn, has rate $r;

match $u isa user, has full-name $fn;

match $bu isa business-unit, has name $n;

match $ur isa user-role, has name $n;

match $ug isa user-group, has name $n;

match $s isa subject, has credential $cr;
slider

Feel free to query data based on abstract supertypes. For example, a query on cars (a supertype) will return all sedans, coupes and SUVs (subtypes). And as new subtypes are added (e.g., crossover), they will automatically be included in the results of queries on their supertype – no code changes necessary. There’s no need to be explicit, and query every subtype.

Learn More

Get started today

Cloud or containers, a database with strong typing, logical abstractions and declarative expressions is minutes away.

Bring the future forward

And show the world what's possible with a strongly typed database.