Uploaded image for project: 'Ignite'
  1. Ignite
  2. IGNITE-18671

Sql. Cast to BigInt with overflow does not produce an error.

    XMLWordPrintableJSON

Details

    • Docs Required, Release Notes Required

    Description

      CREATE TABLE bigints(b BIGINT);
      
      # a bunch of huge values
      statement ok
      INSERT INTO bigints SELECT * FROM table(system_range(4611686018427387904, 4611686018427388903, 1));
      
      # this is too big for a bigint.
      # should fail but returns the result below
      query I
      SELECT SUM(b)::BIGINT FROM bigints
      ----
      499500
      
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            mzhuravkov Maksim Zhuravkov
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: