[
https://issues.apache.org/jira/browse/PHOENIX-1515?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14240603#comment-14240603
]
yang ming commented on PHOENIX-1515:
------------------------------------
[~jamestaylor], my cluster use the same version 4.2.
create table if not exists yk.video_summary
(
videoid integer not null,
date date not null,
platform varchar not null,
device varchar not null,
systemgroup varchar not null,
system varchar not null,
vv bigint,
ts bigint,
up bigint,
down bigint,
comment bigint,
favori bigint,
favord bigint,
quote bigint,
reply bigint
constraint pk primary key (videoid, date,platform, device, systemgroup,system)
)salt_buckets = 30,versions=1,compression='snappy';
create table if not exists yk.video_region
(
videoid integer not null,
date date not null,
platform varchar not null,
device varchar not null,
provinceid varchar not null,
cityid varchar not null,
vv bigint,
ts bigint
constraint pk primary key (videoid, date,platform, device, provinceid, cityid)
)salt_buckets = 30,versions=1,compression='snappy';
> explain time is too long
> ------------------------
>
> Key: PHOENIX-1515
> URL: https://issues.apache.org/jira/browse/PHOENIX-1515
> Project: Phoenix
> Issue Type: Bug
> Affects Versions: 4.2
> Reporter: yang ming
>
> There are two Phoenix tables:YK.VIDEO_SUMMARY_NEW,YK.VIDEO_REGION,primary key
> contains videoid.
> Each table has about 60,000 million rows,before query likes the following
> cost in millisecond,but now quering table YK.VIDEO_REGION cost nearly
> 10s,table YK.VIDEO_SUMMARY_NEW still in millisecond.
> Also the explains have the same results,so what cause this problem?
> 0: jdbc:phoenix:10.103.23.82> select * from YK.VIDEO_SUMMARY_NEW where
> videoid=183705534 and date=to_date('20141203','yyyyMMdd') limit 2;
> +------------+---------------------+------------+------------+-------------+------------+------------+------------+------------+------------+------------+------------+--------+
> | VIDEOID | DATE | PLATFORM | DEVICE | SYSTEMGROUP |
> SYSTEM | VV | TS | UP | DOWN | COMMENT |
> FAVORI | FAVO |
> +------------+---------------------+------------+------------+-------------+------------+------------+------------+------------+------------+------------+------------+--------+
> | 183705534 | 2014-12-03 | app | computer | windows |
> windows | 870 | 663450 | null | null | null |
> null | null |
> | 183705534 | 2014-12-03 | app | mobile | android |
> android | 21639 | 9232508 | null | null | null |
> null | null |
> +------------+---------------------+------------+------------+-------------+------------+------------+------------+------------+------------+------------+------------+--------+
> {color:red}
> 2 rows selected (0.325 seconds)
> {color}
> 0: jdbc:phoenix:10.103.23.82> select * from YK.VIDEO_REGION where
> videoid=183705534 and date=to_date('20141203','yyyyMMdd') limit 2;
> +------------+---------------------+------------+------------+------------+------------+------------+------------+
> | VIDEOID | DATE | PLATFORM | DEVICE | PROVINCEID |
> CITYID | VV | TS |
> +------------+---------------------+------------+------------+------------+------------+------------+------------+
> | 183705534 | 2014-12-03 | app | computer | 11 |
> 110000 | 39 | 30925 |
> | 183705534 | 2014-12-03 | app | computer | 12 |
> 120000 | 20 | 6021 |
> +------------+---------------------+------------+------------+------------+------------+------------+------------+
> {color:red}
> 2 rows selected (8.169 seconds)
> {color}
> 0: jdbc:phoenix:10.103.23.82> explain select * from YK.VIDEO_SUMMARY_NEW
> where videoid=183705534 and date=to_date('20141203','yyyyMMdd') limit 2;
> +------------+
> | PLAN |
> +------------+
> | CLIENT PARALLEL 30-WAY RANGE SCAN OVER YK.VIDEO_SUMMARY_NEW
> [0,183705534,'2014-12-03 00:00:00.000'] |
> | SERVER FILTER BY PageFilter 2 |
> | SERVER 2 ROW LIMIT |
> | CLIENT MERGE SORT |
> | CLIENT 2 ROW LIMIT |
> +------------+
> {color:red}
> 5 rows selected (0.056 seconds)
> {color}
> 0: jdbc:phoenix:10.103.23.82> explain select * from YK.VIDEO_REGION where
> videoid=183705534 and date=to_date('20141203','yyyyMMdd') limit 2;
> +------------+
> | PLAN |
> +------------+
> | CLIENT PARALLEL 30-WAY RANGE SCAN OVER YK.VIDEO_REGION
> [0,183705534,'2014-12-03 00:00:00.000'] |
> | SERVER FILTER BY PageFilter 2 |
> | SERVER 2 ROW LIMIT |
> | CLIENT MERGE SORT |
> | CLIENT 2 ROW LIMIT |
> +------------+
> {color:red}
> 5 rows selected (8.109 seconds)
> {color}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)