>From the screenshot I see the measure "MAX_VALORACION"'s expression is
"SUM", not MAX;

2016-11-26 21:14 GMT+08:00 Alberto Ramón <[email protected]>:

> @ShaoFeng,  You're right
> Queries have same result in Hive and Kylin.
>
> *I only have has a problem with MAX* (don't work. But sum, min, avg works
> OK) (apache-kylin-1.6.0-SNAPSHOT-bin RC1)
>
> SELECT
>     SUM (FACT_VALORACIONES.VALORACION) as SUM_Valoracion
>     ,MIN (FACT_VALORACIONES.VALORACION) as MIN_Valoracion
> --    ,MAX (FACT_VALORACIONES.VALORACION) as MAX_Valoracion
>     ,AVG (FACT_VALORACIONES.VALORACION) as AVG_Valoracion
>
> FROM HERR_BANK.FACT_VALORACIONES as FACT_VALORACIONES
>     INNER JOIN HERR_BANK.DIM_FECHAS as DIM_FECHAS
>         ON FACT_VALORACIONES.IDFECHAVALORACION = DIM_FECHAS.IDFECHA
> Group by DIM_FECHAS.ANYO
>
>
> ERROR:
>  *Can't find any realization. Please confirm with providers*. SQL digest:
> fact table HERR_BANK.FACT_VALORACIONES,group by
> [HERR_BANK.DIM_FECHAS.ANYO],filter on [],with aggregates[FunctionDesc
> [expression=SUM, parameter=ParameterDesc [type=column, value=VALORACION,
> nextParam=null], returnType=null], FunctionDesc [expression=COUNT,
> parameter=ParameterDesc [type=column, value=VALORACION, nextParam=null],
> returnType=null], FunctionDesc [expression=MIN, parameter=ParameterDesc
> [type=column, value=VALORACION, nextParam=null], returnType=null],
> FunctionDesc [expression=MAX, parameter=ParameterDesc [type=column,
> value=VALORACION, nextParam=null], returnType=null]].
>
>
> The result must be:
> [image: Imágenes integradas 1]
>
> Measure definition:
> [image: Imágenes integradas 2]
>
> 2016-11-26 8:20 GMT+01:00 ShaoFeng Shi <[email protected]>:
>
>> Hi Alberto,
>>
>> User need aware that Cube only has aggregated data, no raw data; at the
>> very begining Kylin will throw error on query like "select * "; but to
>> provide a better user experience (also to support some BI tools which need
>> load a subset data to warm up), Kylin answers such query from the base
>> cuboid (group by all dimensions). The measure column value will be the
>> aggregated value; So user could not directly compare the "select *" result
>> from a cube with the source data. If you're comparing the aggregated
>> queries, I believe they are totally the same.
>>
>>
>>
>> 2016-11-26 4:39 GMT+08:00 Alberto Ramón <[email protected]>:
>>
>>> I have a super-Fact Table with 5 rows
>>> [image: Imágenes integradas 2]
>>>
>>>
>>> A- Data in CSV == Hive (OK)
>>> B- Select * from Fact, in Kylin some values are different
>>>
>>> The value 9942758, has been  transformed in 10937033.8 !!!
>>>
>>
>>
>>
>> --
>> Best regards,
>>
>> Shaofeng Shi 史少锋
>>
>>
>


-- 
Best regards,

Shaofeng Shi 史少锋

Reply via email to