Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-6346

Implement Item::not_fixed_dec()

    XMLWordPrintable

Details

    • Task
    • Status: Open (View Workflow)
    • Minor
    • Resolution: Unresolved
    • None
    • None
    • None

    Description

      The fact that an Item has a not fixed number of decimal digits
      is currently stored in Item::decimals as a special value
      NOT_FIXED_DEC (31).

      We should stop using decimal==NOT_FIXED_DEC for that purposes,
      and introduce a new virtual method "bool not_fixed_dec()" instead.

      This should help to avoid bugs like MDEV-4511
      when NOT_FIXED_DEC is erroneously treated as "normal"
      number of decimals.

      Also, there is currently no a way to get the real number of
      decimals from an Item if decimals=NOT_FIXED_DEC, which
      makes calculating decimal precision and scale hard in
      fix_length_and_dec() of some items.

      Attachments

        Activity

          People

            Unassigned Unassigned
            bar Alexander Barkov
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.