MySQL query match with alias WHERE not working

前端 未结 2 1293
你的背包
你的背包 2021-01-24 23:33

why does my sintax is not right?

SELECT *,
           MATCH(tags,title,description) AGAINST (\'asd jhbdckdsb\' IN BOOLEAN MODE) AS score 
      FROM blogs WHERE          


        
相关标签:
2条回答
  • 2021-01-24 23:59

    You cannot use a column alias in the WHERE clause. You must repeat the MATCH a second time.

    0 讨论(0)
  • 2021-01-25 00:10

    invisible columns and column alias are not allowed in WHERE so use HAVING

    HAVING score > 0 instead of WHERE

    0 讨论(0)
提交回复
热议问题