【发布时间】:2015-12-14 02:20:04
【问题描述】:
我想像这样运行 MySQL 查询:
SELECT * FROM `project` WHERE (project.sold_tons + project.recycled_tons + project.recycled_tons + project.donation_tons)*100/project.total_excess_furniture)>90
当我运行它时,我收到如下错误:
#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 ')>90 ORDER BY `is_archived` DESC
LIMIT 0, 25' at line 1
我可以吗? 要么, 有没有其他解决方案可以创建这样的搜索?
如果不是,那么 Laravel 或 MySQL 中的解决方案是什么?
感谢您的帮助..
【问题讨论】:
标签: mysql sql laravel laravel-5 query-builder