Illegal mix of collations error in MySql

后端 未结 19 2293
醉梦人生
醉梦人生 2020-11-29 01:11

Just got this answer from a previous question and it works a treat!

SELECT username, (SUM(rating)/COUNT(*)) as TheAverage, Count(*) as TheCount 
FROM ratings         


        
19条回答
  •  我在风中等你
    2020-11-29 02:01

    • Check that your users.gender column is an INTEGER.
    • Try: alter table users convert to character set latin1 collate latin1_swedish_ci;

提交回复
热议问题