hadoop
[hive] Failed to recognize predicate 'x'. Failed rule: 'identifier' in table or column identifier 해결하기
'김용환'
2017. 2. 23. 17:08
hive 쿼리를 실행 중에 예약어를 쓰면 에러가 발생할 수 있다.
FAILED: ParseException line 1:85 Failed to recognize predicate 'to'. Failed rule: 'identifier' in table or column identifier
이럴 때는 두 가지 방법으로 문제를 해결할 수 있다.
1번째 방법이다.
SET hive.support.sql11.reserved.keywords=false;
select * from src.google_plus_log where date_id='2037-02-22' and to='365600561231231123121212'
2번째 방법은 back quote를 사용한다.
select * from src.google_plus_log where date_id='2037-02-22' and `to`='365600561231231123121212'