Skip to content

Implicit foreign key joins #167

@KyGost

Description

@KyGost

Being able to query tables with partner tables as if they were the same table would be pretty cool.

Not sure if this should be allowed for one-to-many tables.

Example:

SELECT
  person.id,
  person.name,
  person.phone,
  emergency_contact.name,
  emergency_contact.phone
FROM
  person

where

CREATE TABLE person (
  id UINT PRIMARY KEY,
  name SMALL_TEXT,
  phone SMALL_TEXT,
  emergency_contact_id INT FOREIGN KEY REFERENCES person (id)
)
-- Foreign Key doesn't need to be same table, better example could have been used

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions