문제

I have table created by ORM named 'key'. 'key' is MySQL keyword so I cannot select it just SELECT * FROM key;.

How to perform select from table named 'key' in MySQL?

도움이 되었습니까?

해결책

Try to escape your table name with backticks `

SELECT * FROM `key`

This will make your database understand key is a table

다른 팁

you can do

select * from [key]
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top