You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beam.apache.org by "James Xu (JIRA)" <ji...@apache.org> on 2017/05/03 15:00:08 UTC
[jira] [Created] (BEAM-2151) Type mapping inconsistent in
BeamSqlRow & BeamSqlRowCoder
James Xu created BEAM-2151:
------------------------------
Summary: Type mapping inconsistent in BeamSqlRow & BeamSqlRowCoder
Key: BEAM-2151
URL: https://issues.apache.org/jira/browse/BEAM-2151
Project: Beam
Issue Type: Bug
Components: dsl-sql
Reporter: James Xu
In BeamSqlRow, sql FLOAT is mapping to java Float:
```java
case FLOAT:
if (!(fieldValue instanceof Float)) {
throw new InvalidFieldException(
String.format("[%s] doesn't match type [%s]", fieldValue, fieldType));
}
break;
```
but in BeamSqlRowCoder, sql FLOAT is treated as java Double:
```java
case DOUBLE:
case FLOAT:
doubleCoder.encode(value.getDouble(idx), outStream, nested);
break;
```
Let's mapping sql FLOAT consistently to java Float?
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)