Question: Consider the customer table created in Figure 10-24 and populated with data as shown in Figure 10-27. Write the Hive script that will display the
Consider the customer table created in Figure 10-24 and populated with data as shown in Figure 10-27. Write the Hive script that will display the age-groups that exist in the data set and their average incomes.
Figure 10-24

Figure 10-27

CREATE TABLE customer (userid INT, gender STRING, salary INT, zip STRING, age INT) ROW FORMAT DELIMITED FIELDS TERMINATED BY ',';
Step by Step Solution
3.33 Rating (156 Votes )
There are 3 Steps involved in it
Solution Select age avgsalary from customer group by age Explana... View full answer
Get step-by-step solutions from verified subject matter experts
