写爬虫时,最后一步导入MySQL数据库时一直报错:
报错信息:ProgrammingError: (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 ‘‘test’(‘unit’)values(‘元/月’)’ at line 1”)
最后发现,SQL语句的单引号不是正常的单引号,而是TAB键上面的那个!
纠正之后,运行成功!