kylin-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chao Long" <wayn...@qq.com>
Subject Re: Issues regarding multi date columns
Date Fri, 02 Nov 2018 08:39:32 GMT
Hi Feng,
  You are right, It seems a bug here. And would you like to open a jira issue and comtribute
a pr/patch to Kylin?
  As a workaround, You can change the format of  column "day" to String(If it's ok for your
case).




------------------ Original ------------------
From:  "Francis Liang"<soulvagrant@hotmail.com>;
Date:  Fri, Nov 2, 2018 03:59 PM
To:  "user@kylin.apache.org"<user@kylin.apache.org>;

Subject:  Issues regarding multi date columns



  
Hi guys:
 
 
 
I am having an issure regarding using multi date columns as the partition columns for cube
building.
 
 
 
Let’s say I have a fact table with two date partition column: day as the format of integer
(yyyyMMdd) and minute as the format of string (HHmm). I have models created based on it and
set the Partition  Date Column to be “day” with the format of yyyyMMdd and the Partition
Time Column to be “minute” with the format of HHmm. When I build the cube built on top
of that model, I set the Start Date to be 2018-11-01 00:00:00 and the End Date to be 2018-11-01
01:00:00.  The building process is supposed to retrieve the data from the fact table in the
range of “day = 20181101 and minute>=’0000’ and minute<’0100’”. However,
it retrieves the data in the range of “WHERE 1=1 AND (DAY >= 20181101 AND DAY < 20181101),
so no data  are actually retrieved.
 
 
 
When I went through the code, I was confused of the following snippet:
 

 
If I read it right, the partition time column will never be added to the WHERE clause if the
partition date column is type of int or bigint and the date format is "yyyyMMdd", "yyyyMMddHH",
"yyyyMMddHHmm" or "yyyyMMddHHmmss",  which is right my case.
 
 
 
I hope the above clarifies my issue and any help is appreciated.
 
 
 
Best, Feng
Mime
View raw message