Skip to content

Define data field / column types #75

Description

@JoryHogeveen

Currently we do not have any context/information about what fields from datasets contain.
Example with products:

  • name = test field, max # of characters
  • price = float field, or number field
  • active = boolean field

It would be great if we create a way to define field types into our system to give more context in (for example but not limited to) conditionals, datasets, value mappers, value replacers etc.

TODO:

  • Formatters
    • String (w/ trim option)
    • Slug
    • Text
    • Number
    • Price / Currency
    • Date
    • Time
    • DateTime
    • Duration
    • Email
    • Array / List
    • Address
  • Column models
    • Text
    • Slug
    • Boolean
    • Numeric
    • Currency
    • DateTime
    • Duration
    • Email
    • Collection (Array)
    • Schema (Array)
    • Address

Activity

  1. changed the title [-]Data field types[/-] [+]Define data field types[/+] on Nov 8, 2023
  2. added a commit that references this issue on Nov 8, 2023
  3. added this to the v0.1 milestone on Nov 21, 2023
  4. changed the title [-]Define data field types[/-] [+]Define data field / column types[/+] on Dec 6, 2023
  5. JoryHogeveen commented on Dec 6, 2023

    @JoryHogeveen
    MemberAuthor

    @NKoonen Suggestion:

    ColumnModel

    Simple definitions for each column type. Not only the type of variable but also the formatting (regex) etc.
    Modules can then add custom column types to the system.

  6. NKoonen commented on Dec 7, 2023

    @NKoonen
    Member

    @NKoonen Suggestion:

    ColumnModel

    Simple definitions for each column type. Not only the type of variable but also the formatting (regex) etc. Modules can then add custom column types to the system.

    The name ColumnModel tells me it's only available for columns. But it will/should be available for every format of data.
    Example when retrieving a single product from any ERP it's not (always) a column but this function should type cast it to.

    I think this should become a separate task, which apply to datasets and other formats to. Maybe task name ForceType?
    That would also cover the logics for a custom regex if needed.

  7. JoryHogeveen commented on Dec 7, 2023

    @JoryHogeveen
    MemberAuthor

    @NKoonen
    But it is only available for columns. It's meant as a column type module to allow formatting.
    Modules can provide extra column formats specific to their system and SE core will provide the basics (int/float/string /w regex etc.)

    This is unrelated to tasks but indeed, we can create a task that will apply column formats.
    Not only that, if a fields dataset has all the info for the column types we can even autoformat it without any user config needed.

  8. JoryHogeveen commented on Jul 25, 2025

    @JoryHogeveen
    MemberAuthor

    Closing topic. Any extra columns can be suggested as separate topics. I think our current list of columns is already quite complete

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions