로딩
요청 처리 중입니다...

[MySQL] only_full_group_by 오류

 [MySQL] only_full_group_by 오류

Only Full Group By 로컬에서는 멀쩡히 잘 작동하던 쿼리문이 운영 서버에서는 아래와 같은 오류가 뜨며 작동하지 않았다. Expression #2 of SELECT list is not in GROUP BY clause and contains nonaggregated column 'DB명.컬럼명' which is not functionally dependent on columns in GROUP BY clause ; this is incompatible with sql_mode=only_full_group_by GROUP BY 절을 사용하면서 발생한 오류였다.

로컬과 운영쪽 MySQL 버전이나 설정이 다르면 이런 문제가 발생할 수 있다. 12.20.3 MySQL Handling of GROUP BY SQL-92 and earlier does not permit queries for which the select list, HAVING condition, or ORDER ...

# 2 # 취미 # 일상블로그 # 일상 # 일기 # 데이터 # 기록 # 개발자 # 개발 # IT # 컴퓨터