随笔分类 -  mysql学习之路

该文被密码保护。
posted @ 2022-02-25 20:37 小白啊小白,Fighting 阅读(0) 评论(0) 推荐(0) 编辑
摘要:1、备份数据 mysqldump -uroot -pyangxxxx test > ./test.sql 2、重启mysql ,修改数据、然后这个binlog记录pos 、删除数据库 -- service mysqld restart -- show master status; -- show b 阅读全文
posted @ 2021-05-14 13:46 小白啊小白,Fighting 阅读(121) 评论(0) 推荐(0) 编辑
摘要:1、下载并安装 https://zeppelin.apache.org/docs/0.8.0/quickstart/install.html#building-zeppelin-from-source #官网https://mirrors.tuna.tsinghua.edu.cn/apache/ze 阅读全文
posted @ 2021-04-08 14:46 小白啊小白,Fighting 阅读(457) 评论(0) 推荐(0) 编辑
摘要:知识点 存储过程参考博客:https://www.cnblogs.com/nnngu/p/8463399.html 分区表参考博客:https://www.cnblogs.com/duanxz/p/3825155.html https://www.cnblogs.com/pejsidney/p/10 阅读全文
posted @ 2021-02-22 17:52 小白啊小白,Fighting 阅读(158) 评论(0) 推荐(0) 编辑
摘要:注意 1、python脚本一定要注意空格,否则这种报错无法做出判断 2、脚本魔法 请根据自己python的路径填写 1、脚本代码 #! /root/anaconda3/bin/python import pymysql import datetime #参数值插入时间 #连接数据库 db = pym 阅读全文
posted @ 2021-01-21 14:12 小白啊小白,Fighting 阅读(318) 评论(0) 推荐(0) 编辑
该文被密码保护。
posted @ 2020-11-13 11:02 小白啊小白,Fighting 阅读(186) 评论(0) 推荐(0) 编辑
摘要:1、sql语句优化 可以查看牛人博客:https://www.cnblogs.com/linyue09/p/9869163.html 2、mysql性能查看 1、查看 profile 开启情况 select @@profiling; 开启profile:set profiling = 1; 2、查看 阅读全文
posted @ 2020-08-21 11:06 小白啊小白,Fighting 阅读(152) 评论(0) 推荐(0) 编辑
摘要:1、并集: a和b所有元素的集合 -- 全连接 并集: a和b所有元素的集合 SELECT a.id id , a.user_name ausername, a.score ascore , b.user_name busername ,b.score bscore FROM cj a LEFT J 阅读全文
posted @ 2020-08-10 11:45 小白啊小白,Fighting 阅读(842) 评论(0) 推荐(1) 编辑
摘要:#查看mysql当前存在的事务,如果存在死锁,则会记录select * from information_schema.innodb_trx ;#删除当前事务的死锁进程。kill trx_mysql_thread_id 阅读全文
posted @ 2020-01-15 16:48 小白啊小白,Fighting 阅读(694) 评论(0) 推荐(0) 编辑
摘要:注意: 主库挂了,从库也无法进行插入和查询 从库挂了,主库可以插入,但不能进行查询 #在服务端实现读写分离 注意:mysql的主从配置可以看:https://www.cnblogs.com/ywjfx/p/10264383.html 1、安装mycat1.6 下载地址:http://dl.mycat 阅读全文
posted @ 2019-01-25 17:26 小白啊小白,Fighting 阅读(1852) 评论(0) 推荐(0) 编辑
摘要:如果开始是单机mysql需要先同步数据到slave mysqldump -h主数据库ip -uroot -p123456 --default-character-set=utf8 --databases test --single-transaction --master-data=2 > test 阅读全文
posted @ 2019-01-13 22:37 小白啊小白,Fighting 阅读(1246) 评论(0) 推荐(0) 编辑
摘要:声明:安装来自https://www.cnblogs.com/starof/p/4680083.html mysql5.6安装:https://www.cnblogs.com/starof/p/4680083.html mysql5.7安装:https://blog.csdn.net/EB_NUM/ 阅读全文
posted @ 2019-01-13 20:31 小白啊小白,Fighting 阅读(134) 评论(0) 推荐(0) 编辑
摘要:1、将两个表字段类型一致的数据合并到一个新表的命令。 INSERT into new_table(user_name,password,age) SELECT user_name,password,age FROM old_table1; INSERT into new_table(user_nam 阅读全文
posted @ 2018-12-12 11:26 小白啊小白,Fighting 阅读(164) 评论(0) 推荐(0) 编辑
摘要:题记:强迫症需求,一个小技巧。 亲测有效 注意:主键id只针对int类型,bigint不可以使用。但是可以先将字段改为int,使用下面命令修改后,再将字段改为bigint类型即可。 阅读全文
posted @ 2018-11-22 10:14 小白啊小白,Fighting 阅读(2079) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示