如何修复错误#1064 mysql [英] How to fix error #1064 mysql
问题描述
我有下面的SQL查询,假设显示2列是描述和状态。但是当我执行查询时,会显示#1064错误。请指教。谢谢。
SELECT`Projecttable`.Description,If(Description =Complete,Yes,If(Description =Inprogress,No))AS`状态`
来自`Projecttable`;
我尝试了什么:
我试图将`Description`作为查询,但会再次显示#1064错误。请指教。谢谢。
SELECT`Projecttable``Description`,If(Description =Complete,Yes,If(Description =Inprogress,No)) AS`状态`
来自`Projecttable`;
IF
需要3参数: MySQL :: MySQL 5.7参考手册:: 13.4控制流功能 [ ^ ]
Hi, i have this sql queries below that suppose to display 2 columns that is Description and Status. But when i execute the query the #1064 error is displayed. Please advise. Thanks.
SELECT `Projecttable`.Description, If(Description="Complete","Yes",If(Description="Inprogress","No")) AS `Status`
FROM `Projecttable`;
What I have tried:
I have tried to put the `Description` as queries below but the #1064 error is displayed again. Please advise. Thanks.
SELECT `Projecttable`.`Description`, If(Description="Complete","Yes",If(Description="Inprogress","No")) AS `Status`
FROM `Projecttable`;
IF
takes 3 arguments : MySQL :: MySQL 5.7 Reference Manual :: 13.4 Control Flow Functions[^]
这篇关于如何修复错误#1064 mysql的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!