toooki
asked on
Hive query question
I have a table in hive:
table1
f1 f2
x 10
y 20
p 40
q 55
How can I query the above table in hive to obtain one record like the following:
x:10, y:20, p:40, q:55
Thank you.
table1
f1 f2
x 10
y 20
p 40
q 55
How can I query the above table in hive to obtain one record like the following:
x:10, y:20, p:40, q:55
Thank you.
ASKER
I am using Apache Hive.
In looking at the Hive language manual it uses fairly standard SQL
SELECT * FROM sales WHERE amount > 10 AND region = "US"
Link to the language manual
https://cwiki.apache.org/confluence/display/Hive/LanguageManual
mlmcc
SELECT * FROM sales WHERE amount > 10 AND region = "US"
Link to the language manual
https://cwiki.apache.org/confluence/display/Hive/LanguageManual
mlmcc
My guess would be some combination of ClusterBy and Transform, however, I have no way to test this.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
What language are you using?