我正在蜂巢中运行以下查询:-
CREATE TABLE IF NOT EXISTS database1.table2
AS SELECT A.company,A.amount,
NTILE(100) OVER(PARTITION BY A.company ORDER BY A.amount DESC) as pct
FROM (select company, amount from database1.table1
where trim(INDICATOR) = 'Debit' and trim(company)='1000' and amount IS NOT NULL)A;
上面的查询对于7M数据运行完美。但是,对于122M运行相同的查询,查询将在99%处停止。