[
https://issues.apache.org/jira/browse/KYLIN-3776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16747936#comment-16747936
]
ASF subversion and git services commented on KYLIN-3776:
--------------------------------------------------------
Commit e413a812690ceaff07f093514b328eee8baeb40d in kylin's branch
refs/heads/master from hit-lacus
[ https://gitbox.apache.org/repos/asf?p=kylin.git;h=e413a81 ]
KYLIN-3776 Float type in MySQL not properly converted to HIVE Double Type
> Float type in MySQL not properly converted to HIVE Double Type
> --------------------------------------------------------------
>
> Key: KYLIN-3776
> URL: https://issues.apache.org/jira/browse/KYLIN-3776
> Project: Kylin
> Issue Type: Bug
> Components: RDBMS Source
> Affects Versions: v2.6.0
> Reporter: Hubert STEFANI
> Assignee: XiaoXiang Yu
> Priority: Major
> Fix For: v2.6.1
>
>
>
> when loading a table from mysql as source, the float type is converted as
> HIVE Double type, but a precision information is added which gives an error
> while creating hive table.
> {quote}CREATE EXTERNAL TABLE IF NOT EXISTS
> kylin_intermediate_cube_commande_777b5b14_570a_338a_25b4_b55ad6388a93
> (
> COMMANDE_COM_CODE_POSTAL int
> ,COMMANDE_COM_COMMUNE string
> ... ,COMMANDE_COM_MONTANT double(12)
> )
> {quote}
> the correct code should be :
> {quote}... ,COMMANDE_COM_MONTANT double
> {quote}
> It seems that SqlUtil class should not include "double" as a type with scale
> {color:#000080}public static boolean {color}isScaleApplicable(String
> typeName) {
> {color:#000080}return
> {color}DataType.{color:#660e7a}NUMBER_FAMILY{color}.contains(typeName) &&
> !DataType.{color:#660e7a}INTEGER_FAMILY{color}.contains(typeName);
> }
> should be changed for something similar to :
>
> {color:#000080}public static boolean {color}isScaleApplicable(String
> typeName) {
> {color:#000080}return
> {color}!{color:#008000}"double"{color}.equals(typeName) &&
> DataType.{color:#660e7a}NUMBER_FAMILY{color}.contains(typeName) &&
> !DataType.{color:#660e7a}INTEGER_FAMILY{color}.contains(typeName);
> }
>
>
>
>
>
>
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)