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

LP:736358 - Unexpected increased timestamp resolution with UNION

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Minor
    • Resolution: Fixed
    • None
    • None
    • None

    Description

      When executed in a UNION context, datetime operations return a millisecond precision, even though no fractional seconds were used anywhere in the expression.

      Test case:

      CREATE TABLE t1 (f1 timestamp(6));
      INSERT INTO t1 VALUES ('2002-07-15 21:00:00');

      SELECT TIME(f1) FROM t1;

      returns:

      21:00:00

      ( SELECT TIME(f1) FROM t1) UNION ALL ( SELECT TIME(f1) FROM t1);

      returns
      21:00:00.000000
      21:00:00.000000

      Attachments

        Activity

          People

            serg Sergei Golubchik
            philipstoev Philip Stoev (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Git Integration

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