码迷,mamicode.com
首页 >  
搜索关键字:schema    ( 4682个结果
SQLSTATE[42S01]: Base table or view already exists: 1050 Table 'xxx' already exists
字面意思 xxx表已存在. 在使用laravel 写同步结构的时候 最好习惯性写个if语句判定是否存在 // 判断数据表是否存在 Schema::hasTable('table'); // 判断数据表是否有该列 Schema::hasColumn('table', 'column'); 实例: pu ...
分类:数据库   时间:2020-05-27 10:34:04    阅读次数:93
spring的依赖注入
<?xml version="1.0" encoding="UTF-8"?><beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" ...
分类:编程语言   时间:2020-05-27 00:44:09    阅读次数:71
[Go] 浅谈 gorm 执行 AutoMigrate 的两种时机
第一种就是直接在操作 model 的逻辑中,执行 db.AutoMigrate,模型没有更新时不会有 schema 相关的 sql 被执行。 第二种就是单独定义一个属于 main 包的 go 文件,专门用于处理 Migrate。 有其它想法欢迎留言。 Link:https://www.cnblogs ...
分类:其他好文   时间:2020-05-26 20:41:49    阅读次数:298
解决:navicat出现Table ‘performance_schema.session_variables’ doesn’t exist报错,解决过程中出现mysql遇到的cannot select database 问题
问题描述: navicat连接本地MySQL时出现Table ‘performance_schema.session_variables’ doesn’t exist报错。网上的解决方法是在mysql的bin目录下运行 mysql_upgrade -u root -p --force命令,但是我在输 ...
分类:数据库   时间:2020-05-26 20:21:47    阅读次数:112
mysql 查询表结构
查看表中字段的结构信息 可以用来查看表中字段的注释等,比如 select table_name,column_name,column_comment from information_schema.columns where table_schema ='表所在的库' and table_name ...
分类:数据库   时间:2020-05-25 12:11:59    阅读次数:80
查询被锁住&执行慢
查询长时间不返回。 等MDL锁 有一个线程正在表t上请求或者持有MDL写锁,把select语句堵住了 处理方式: 找到谁持有MDL写锁,然后把它kill掉 查找方式: 1. mysql启动时设置 performance_schema=on 2. 等flush 1. session A,每行都调用一次 ...
分类:其他好文   时间:2020-05-24 12:10:32    阅读次数:84
SSM综合练习
CRM练习 applicationContext-dao.xml(数据源和mabatis配置) <?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.springframework.org/schema/beans" xmln ...
分类:其他好文   时间:2020-05-24 09:30:56    阅读次数:57
MySQL 查询数据库中某个表的所有字段名、字段类型以及注释
通过SQL语句,查询某个表中包含的字段名。SQL 语句如下: select COLUMN_NAME,DATA_TYPE,COLUMN_COMMENT from information_schema.COLUMNS where table_name = '表名' and table_schema = ...
分类:数据库   时间:2020-05-23 09:42:12    阅读次数:99
ThinKPHP6.0 上手操作
ThinKPHP6.0 上手 安装 ThinkPHP6.0 cd 切换到项目目录,然后执行如下 准备安装框架:composer create project topthink/think thinkPHP6.0 cd 切换到PHP项目 thinkPHP6.0 目录中 修改配置文件:.env 配置文件 ...
分类:Web程序   时间:2020-05-22 15:37:08    阅读次数:72
MySQL 4.1/5.0/5.1/5.5/5.6/5.7各版本的主要区别
mysql的50版本和51版本的区别:一、5.0 增加了Stored procedures、Views、Cursors、Triggers、XA transactions的支持,增加了INFORATION_SCHEMA系统数据库。 二、5.1 增加了Event scheduler,Partitioni ...
分类:数据库   时间:2020-05-22 12:58:05    阅读次数:132
4682条   上一页 1 ... 24 25 26 27 28 ... 469 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!