Skip to content

Why from_id, to_id, and type_id do not have the same type and default values? #205

@konard

Description

@konard

https://github.com/deepcase/deeplinks/blob/94d5926fdfaa0003c4a9c28980840d66512fdc4f/migrations/1616701513782-links.ts#L19

CREATE TABLE ${SCHEMA}."${TABLE_NAME}" (
  id bigint PRIMARY KEY,
  from_id bigint DEFAULT 0,
  to_id bigint DEFAULT 0,
  type_id bigint NOT NULL);

As far as I understand at the moment, from_id and to_id are nullable, but have 0 as a default value.
Type is not nullable, but it has no default value.


Forked from deep-foundation/deeplinks#15 by https://github.com/konard/gh-org-migrator

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions