Re: Creating temp tables in select statements

2019-03-28 Thread Edward Capriolo
I made a udtf a while back that's let's you specify lists of tuples from there you can explode them into rows On Thursday, March 28, 2019, Jesus Camacho Rodriguez < jcamachorodrig...@hortonworks.com> wrote: > Depending on the version you are using, table + values syntax is supported. > > https://

Re: Creating temp tables in select statements

2019-03-28 Thread Jesus Camacho Rodriguez
Depending on the version you are using, table + values syntax is supported. https://issues.apache.org/jira/browse/HIVE-18416 SELECT a, b FROM TABLE(VALUES(1,2),(3,4)) AS x(a,b); -Jesús From: David Lavati Reply-To: "user@hive.apache.org" Date: Thursday, March 28, 2019 at 4:44 AM To: "user@hive

Re: Creating temp tables in select statements

2019-03-28 Thread David Lavati
Hi Mainak, For select queries the only way I know of for multiple records is through using union: 0: jdbc:hive2://localhost:1> with x as (select 1 num union select 2 union select 3) select * from x; ++ | x.num | ++ | 1 | | 2 | | 3 | ++ For table insert

Random failure in HIVE tez engine

2019-03-28 Thread Saurabh Mishra
Hi, While running the following query with 'tez' execution engine am getting ArrayOutOfBound exception. Not sure why, but any suggestion would be appreciated. Query : select distinct -1, -1; Distribution : HDP HIVE Version : 2.6.3.0-235 Execution Engine : tez Error Message : Caused by: org.apa