Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我不知道如何执行查询以选择 field_x (minus) field_y 低于 equal 的位置?
样本 : SELECT * FROM $tableName WHERE Field_X - Fiel_Y < 50
SELECT * FROM $tableName WHERE Field_X - Fiel_Y < 50
你的意思是低于或等于某个常数?
SELECT * FROM $tableName WHERE Field_X - Field_Y <= 50
根据你的问题,应该是这样
SELECT * FROM tableName WHERE Field_X - Field_Y <= 50