• 博客园logo
  • 会员
  • 周边
  • 新闻
  • 博问
  • 闪存
  • 众包
  • 赞助商
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录

jwang106


脚踏实地,日拱一卒。 建立新的神经链接,可不像公园散步那样简单。
  • 博客园
  • 联系
  • 管理

随笔分类 -  技术 - mysql

Union比or快 Using UNION is faster when it comes to cases like scan two different column。
摘要:problem: 595. Big Countries A country is big if it has an area of bigger than 3 million square km or a population of more than 25 million. Write a SQL 阅读全文

posted @ 2019-08-25 10:01 jwang106 阅读(304) 评论(0) 推荐(0)

django.core.exceptions.ImproperlyConfigured: mysqlclient 1.3.13 or newer is required; you have 0.9.3.
摘要:pip install mysqlclient 在init里 阅读全文

posted @ 2019-08-11 22:20 jwang106 阅读(245) 评论(0) 推荐(0)

LOAD CSV ERROR: The used command is not allowed with this MySQL version
摘要:要执行的sql 把csvload进db 把客户端和server端 local_infile 都设置为True/ON 阅读全文

posted @ 2019-08-10 08:20 jwang106 阅读(470) 评论(0) 推荐(0)

MySql在建立索引优化时需要注意的问题
摘要:MySql在建立索引优化时需要注意的问题 设计好MySql的索引可以让你的数据库飞起来,大大的提高数据库效率。设计MySql索引的时候有一下几点注意: 1,创建索引 对于查询占主要的应用来说,索引显得尤为重要。很多时候性能问题很简单的就是因为我们忘了添加索引而造成的,或者说没有添加更为有效的索引导致 阅读全文

posted @ 2019-07-24 16:04 jwang106 阅读(1169) 评论(0) 推荐(0)

数据库分库分表
摘要:数据库架构演变 刚开始我们只用单机数据库就够了,随后面对越来越多的请求,我们将数据库的写操作和读操作进行分离, 使用多个从库副本(Slaver Replication)负责读,使用主库(Master)负责写, 从库从主库同步更新数据,保持数据一致。架构上就是数据库主从同步。 从库可以水平扩展,所以更 阅读全文

posted @ 2019-07-18 12:11 jwang106 阅读(184) 评论(0) 推荐(0)

ubuntu安装mysql 并对外暴露3306端口
摘要:安装 sudo apt get install mysql client mysql server 1. vi /etc/mysql/mysql.conf.d/mysqld.cnf bind 127注掉 2. mysql.user 授权 update mysql.user set host = ‘% 阅读全文

posted @ 2019-07-18 12:07 jwang106 阅读(1426) 评论(0) 推荐(0)

ElasticSearch Roaring bitmap 和跳表联合查询
摘要:ElasticSearch Roaring map 1. 先把所有数按65535划分, 划分方法就是求商和余数,商代表数字最终在哪一块,余数代表最终在块内的数字 比如 1, 65536, 65537, 131073 则分成三个block: 1 | 1,2 | 3 2. 对每一块的数据做判断,如果数据 阅读全文

posted @ 2019-05-15 11:26 jwang106 阅读(2205) 评论(0) 推荐(0)

mac 安装 pymssql 报错
摘要:报错信息 _mssql.c:346:10: fatal error: 'sqlfront.h' file not found include "sqlfront.h" ^~~~~~~~~~~~ 1 error generated. error: command 'clang' failed with 阅读全文

posted @ 2019-04-16 19:30 jwang106 阅读(503) 评论(0) 推荐(0)

mysql删除字段为null的数据
摘要:delete FROM main_bussiness_cost1 where date is null; 不能用 date = null; 阅读全文

posted @ 2019-01-17 12:00 jwang106 阅读(916) 评论(0) 推荐(0)

mysql 第一次启动及常用命令
摘要:启动 进入后 修改timestamp格式 alter table table_name change `t1` TIMESTAMP(6) NOT NULL default '2000 01 01 00:00:00.00001'; 阅读全文

posted @ 2019-01-14 11:57 jwang106 阅读(741) 评论(0) 推荐(0)

mac 安装并使用 mysql 或者 mac mysql 忘记密码,Can't connect to local MySQL server through socket homebrew
摘要:1. brew install mysql 2. 启动mysql mysql.server start 我遇到了这个error,查openstack解决,我在这粘一下 ### Error:Can't connect to local MySQL server through socket homeb 阅读全文

posted @ 2018-12-28 20:13 jwang106 阅读(343) 评论(0) 推荐(0)

mysql数据库名有 横杠 横线 - dash 怎么办
摘要:'''SELECT date FROM `%s` ORDER BY date DESC LIMIT 1''' % 'ZXS-QZCSCRB-3'重点就是这个符号 ` 键盘左上角 阅读全文

posted @ 2018-12-27 15:27 jwang106 阅读(1841) 评论(0) 推荐(0)

 
博客园  ©  2004-2026
浙公网安备 33010602011771号 浙ICP备2021040463号-3