0
select c.*
from costs c
where 32 between c.x and c.x + c.deltax and 34 between c.y + c.deltay
order by priority desc
limit 1

と言い続けます#1064 - 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 'order by priority desc limit 1' at line 4。私は何が欠けていますか?

4

1 に答える 1

2

あなたの2番目betweenに確認する条件は1つだけです。次のものがありませんand

34 between c.y + c.deltay

使いたいですか?

34 between c.y and c.y + c.deltay
于 2013-04-16T11:17:21.130 に答える