trafodion-codereview mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From DaveBirdsall <...@git.apache.org>
Subject [GitHub] incubator-trafodion pull request #555: JIRA TRAFODION-2084 Handling of inval...
Date Wed, 22 Jun 2016 20:54:11 GMT
Github user DaveBirdsall commented on a diff in the pull request:

    https://github.com/apache/incubator-trafodion/pull/555#discussion_r68133142
  
    --- Diff: core/sql/sqlcomp/nadefaults.cpp ---
    @@ -4825,7 +4826,21 @@ Int32 NADefaults::validateFloat(const char *value, float &result,
     {
       Int32 n = -1;	// NT's scanf("%n") is not quite correct; hence this code-around
       sscanf(value, "%g%n", &result, &n);
    -  if (n > 0 && value[n] == '\0') return TRUE;	// a valid float
    +  if (n > 0 && value[n] == '\0') 
    +    {
    +      switch (attrEnum)
    +        {
    +        case HIVE_INSERT_ERROR_MODE:
    --- End diff --
    
    Not sure why this is needed. Why not follow the model, say, of validateUIntFrom0To5? (that
is, add your own validateUIntFrom0To3)


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message