Uploaded image for project: 'Apache Trafodion (Retired)'
  1. Apache Trafodion (Retired)
  2. TRAFODION-2750

Using function strtod is not enough to convert C_CHAR to DOUBLE

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Won't Fix
    • 2.2.0, 2.3
    • 2.2.0
    • client-odbc-linux
    • None
    • centos6.7

    Description

      client app with odbc driver :
      insert c_char "-2.22507e-308"; to double
      State: 22003
      Native Error: 0
      Error: [Trafodion ODBC Driver] NUMERIC VALUE OUT OF RANGE. Incorrect Format or Data. Row: 1 Column: 1

      unit test for driver code :
      char buffer[] = "-2.22507e-308";
      double db;
      errno = 0;
      db = strtod(buffer,NULL);

      return db = -0.000000
      errno = 34

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              XuWeixin XuWeixin
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: