首页 > 数据库技术 > 详细

Django中创建数据库报错:ERROR 1064 (42000): 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 '=utf8' at line 1解决方案

时间:2020-07-18 11:28:24      阅读:434      评论:0      收藏:0      [点我收藏+]

一、问题描述

  Django中执行create database charset=utf8;命令报错:ERROR 1064 (42000): 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 ‘=utf8‘ at line 1

 

二、问题原因

  数据库名称没有用反引号引起来

三、解决方案

  创建数据库时使用以下命令即可:

    create ‘ database‘ charset=utf8;

    

技术分享图片

 

Django中创建数据库报错:ERROR 1064 (42000): 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 '=utf8' at line 1解决方案

原文:https://www.cnblogs.com/lxmtx/p/13334473.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!