Skip to content

Add NullTable#173

Merged
ocharles merged 2 commits intomasterfrom
NullTable
May 20, 2022
Merged

Add NullTable#173
ocharles merged 2 commits intomasterfrom
NullTable

Conversation

@shane-circuithub
Copy link
Copy Markdown
Contributor

This is an alternative to MaybeTable that doesn't use a tag columns. It's less flexible (no Functor or Applicative instance) and is meaningless when used with a table that has no non-nullable columns (so nesting NullTable is redundant). But in situations where the underlying Table does have non-nullable columns, it can losslessly converted to and from MaybeTable.

It is useful for embedding into a base table when you don't want to store the extra tag column in your schema.

shane-circuithub and others added 2 commits May 17, 2022 12:34
This is an alternative to `MaybeTable` that doesn't use a tag columns. It's less flexible (no `Functor` or `Applicative` instance) and is meaningless when used with a table that has no non-nullable columns (so nesting `NullTable` is redundant). But in situations where the underlying `Table` does have non-nullable columns, it can losslessly converted to and from `MaybeTable`.

It is useful for embedding into a base table when you don't want to store the extra tag column in your schema.
@ocharles ocharles merged commit 99e868b into master May 20, 2022
@ocharles ocharles deleted the NullTable branch May 20, 2022 11:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants