且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何在MySQL的where子句中使用别名

更新时间:2023-01-19 23:34:40

这可能是由于where子句中的lessor而不是lessor_name引起的.因此,请尝试以下方法:

It might be due to lessor instead of lessor_name in where clause. So try with below once :

SELECT CONCAT_WS(" ", strLname, strFname, strMname) AS lessor_name 
FROM tbl_lessor 
having lessor_name= '$lessor_name'