Skip to content

Resolve UI confusion with two separate "Decimal Places" type options #1420

@seancolsen

Description

@seancolsen

Current behavior

  • The "Number" UI type has a display option for "Decimal Places" which controls minimum_fraction_digits and maximum_fraction_digits?
  • Additionally, within the DB options, when "Number Type" = "Decimal", it will have a DB option for "Decimal Places" to control the Postgres SCALE value.
  • The two "Decimal Places" fields do different things, but together they are confusing as presented.

Design questions to answer

  • Do we want to allow the user to control the SCALE and PRECISION values?

    Things to consider:

    • The DB may have values set for those parameters outside of Mathesar.
    • There may be valid use cases for setting SCALE. For example, if I'm storing dollar values and I want to ensure that none of my values have fractional cents.
  • If so, how do we design the UI to make a clear distinction between SCALE and minimum_fraction_digits/maximum_fraction_digits?

Related issues

Metadata

Metadata

Assignees

No one assigned

    Labels

    needs: ux designtemp: discussThis issue n eeds discussion to resolve - part of the Oct 2025 backlog grooming process.type: enhancementwork: frontendRelated to frontend code in the mathesar_ui directory

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions