Well, I must say sorry that there was a mistake in the last email. The maximum number of the valid keys is 32 in my test. Namely, key33~key50 get null values in the code. Still waiting for more details, thanks!
Regards, 孙志禹 发件人: 孙志禹 发送时间: 2019-02-21 13:18 收件人: user@hive.apache.org 主题: Limit to the max number of fields in GROUPING SETS Dear all, by doing some tests, I found there is a limit to the number of fields used in GRPOUPING SETS. For example, in the code below, we can only get null value for key44~key50. In addition, if we change the order of the keys, we can always get null value for the last several keys. Can anyone give some more details about this limit? Thanks! ―――――――――――――――――――――――――――――――――――― SELECT key1,key2,key3,key4,key5,key6,key7,key8,key9,key10 ,key11,key12,key13,key14,key15,key16,key17,key18,key19,key20 ,key21,key22,key23,key24,key25,key26,key27,key28,key29,key30 ,key31,key32,key33,key34,key35,key36,key37,key38,key39,key40 ,key41,key42,key43,key44,key45,key46,key47,key48,key49,key50 FROM table1 GROUP BY key1,key2,key3,key4,key5,key6,key7,key8,key9,key10 ,key11,key12,key13,key14,key15,key16,key17,key18,key19,key20 ,key21,key22,key23,key24,key25,key26,key27,key28,key29,key30 ,key31,key32,key33,key34,key35,key36,key37,key38,key39,key40 ,key41,key42,key43,key44,key45,key46,key47,key48,key49,key50 grouping sets ( ( key1,key2,key3,key4,key5,key6,key7,key8,key9,key10 ,key11,key12,key13,key14,key15,key16,key17,key18,key19,key20 ,key21,key22,key23,key24,key25,key26,key27,key28,key29,key30 ,key31,key32,key33,key34,key35,key36,key37,key38,key39,key40 ,key41,key42,key43,key44,key45,key46,key47,key48,key49,key50 ) ) ―――――――――――――――――――――――――――――――― Regards, 孙志禹(Zhiyu Sun)