mysql在linux下去分表名大小写的问题_MySQL
bitsCN.com
我做开发时候是用windows 的 所以没感觉
今天部署自己做的一个yii 项目到linux的时候发现的一个问题,
yii 的rbac 的表找不到 报错如下
CDbCommand 无法执行 SQL 语句: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'si_manager.AuthAssignment' doesn't exist. The SQL statement executed was: SELECT * FROM `AuthAssignment` WHERE userid=:userid
但是我去看我linux的机器是有这个数据表的
仔细看提示,是大小写略微不同,之后手工执行出错的语句,同样报错,于是确定是大小写问题
于是google 得知mysql在linux下表名是去分大小写的 只不过有配置改成不区分 非常简单
在/etc/my.cnf 里的[mysqld] 下面增加lower_case_table_names=1 这一句话即可.

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics



Regarding the problem of removing the Python interpreter that comes with Linux systems, many Linux distributions will preinstall the Python interpreter when installed, and it does not use the package manager...

Configure the apscheduler timing task as a service on macOS platform, if you want to configure the apscheduler timing task as a service, similar to ngin...

Using python in Linux terminal...

Mastering Debian system log monitoring is the key to efficient operation and maintenance. It can help you understand the system's operating conditions in a timely manner, quickly locate faults, and optimize system performance. This article will introduce several commonly used monitoring methods and tools. Monitoring system resources with the sysstat toolkit The sysstat toolkit provides a series of powerful command line tools for collecting, analyzing and reporting various system resource metrics, including CPU load, memory usage, disk I/O, network throughput, etc. The main tools include: sar: a comprehensive system resource statistics tool, covering CPU, memory, disk, network, etc. iostat: disk and CPU statistics. mpstat: Statistics of multi-core CPUs. pidsta

Why can't my code get the data returned by the API? In programming, we often encounter the problem of returning null values when API calls, which is not only confusing...

"DebianStrings" is not a standard term, and its specific meaning is still unclear. This article cannot directly comment on its browser compatibility. However, if "DebianStrings" refers to a web application running on a Debian system, its browser compatibility depends on the technical architecture of the application itself. Most modern web applications are committed to cross-browser compatibility. This relies on following web standards and using well-compatible front-end technologies (such as HTML, CSS, JavaScript) and back-end technologies (such as PHP, Python, Node.js, etc.). To ensure that the application is compatible with multiple browsers, developers often need to conduct cross-browser testing and use responsiveness

Regarding the choice of Debian system, this article will explore the advantages of Debian system and help you determine whether it is suitable for your needs. The image shows the missing search results related to DebianStrings, which prompts us to look at the Debian system from a broader perspective. Debian Community & Stability: Debian is known for its large and active open source community, which means you can easily access a large amount of documentation, tutorials, and community support to quickly resolve issues you encounter. The stability of the system is also a highlight of Debian, especially in the server environment, which is much more stable than other distributions. Debian vs. Ubuntu: Compared with Ubuntu, Debian

DebianLinux is known for its stability and security and is widely used in server, development and desktop environments. While there is currently a lack of official instructions on direct compatibility with Debian and Hadoop, this article will guide you on how to deploy Hadoop on your Debian system. Debian system requirements: Before starting Hadoop configuration, please make sure that your Debian system meets the minimum operating requirements of Hadoop, which includes installing the necessary Java Runtime Environment (JRE) and Hadoop packages. Hadoop deployment steps: Download and unzip Hadoop: Download the Hadoop version you need from the official ApacheHadoop website and solve it
