Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

How to get Column names in uppercase using impala

How to get Column names in uppercase using impala

New Contributor
When we have column names in query, always impala returns column names in lowercase. I’d greatfull if you could let us know how to get column names in uppercase.

Thanks in advance.
3 REPLIES 3

Re: How to get Column names in uppercase using impala

Cloudera Employee

In Impala, the identifiers are always case-insensitive. i.e., tables named t1 and T1 always refer to the same table, regardless of quote characters. Internally, Impala always folds all specified table and column names to lowercase. This is why the column headers in query output are always displayed in lowercase.

 

Aliases follow the same rules as identifiers when it comes to case insensitivity. 

 

More information on Cloudera's Impala documentation: 

 

https://www.cloudera.com/documentation/enterprise/latest/topics/impala_identifiers.html

Re: How to get Column names in uppercase using impala

New Contributor
Is there any way to get the aliases in specified format? For example, SELECT c1 AS “Employee ID” from EMPLOYEE;
Result of the above query should return as below:
Employee ID
——————
1
2
Instead of below
employee id
——————
1
2

Thanks in advance

Re: How to get Column names in uppercase using impala

Cloudera Employee

I do not see any such option available yet.

Don't have an account?
Coming from Hortonworks? Activate your account here