
* 겪고 있는 문제 상황을 최대한 자세하게 작성해주세요.
* 문제 해결을 위해 어떤 시도를 해보았는지 구체적으로 함께 알려주세요.
select restaurant_name "원래 이름",
addr "원래 주소",
concat(restaurant_name, '-', cuisine_type) "음식타입별 음식점"
concat('[', substring(addr, 1, 2), '] ', restaurant_name) "바뀐 이름"
from food_orders
where addr like '%서울%'
라고 입력했는데 오류로 수식이 작동하지 않아요.
오류문구는 다음과 같습니다.
SQL Error [1064] [42000]: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'concat('[', substring(addr, 1, 2), '] ', restaurant_name) "바뀐 이름"
from f' at line 4
Error position: line: 3
