摘要: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
阅读全文
摘要:要执行的sql 把csvload进db 把客户端和server端 local_infile 都设置为True/ON
阅读全文
摘要:MySql在建立索引优化时需要注意的问题 设计好MySql的索引可以让你的数据库飞起来,大大的提高数据库效率。设计MySql索引的时候有一下几点注意: 1,创建索引 对于查询占主要的应用来说,索引显得尤为重要。很多时候性能问题很简单的就是因为我们忘了添加索引而造成的,或者说没有添加更为有效的索引导致
阅读全文
摘要:数据库架构演变 刚开始我们只用单机数据库就够了,随后面对越来越多的请求,我们将数据库的写操作和读操作进行分离, 使用多个从库副本(Slaver Replication)负责读,使用主库(Master)负责写, 从库从主库同步更新数据,保持数据一致。架构上就是数据库主从同步。 从库可以水平扩展,所以更
阅读全文
摘要:安装 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 = ‘%
阅读全文
摘要:ElasticSearch Roaring map 1. 先把所有数按65535划分, 划分方法就是求商和余数,商代表数字最终在哪一块,余数代表最终在块内的数字 比如 1, 65536, 65537, 131073 则分成三个block: 1 | 1,2 | 3 2. 对每一块的数据做判断,如果数据
阅读全文
摘要:报错信息 _mssql.c:346:10: fatal error: 'sqlfront.h' file not found include "sqlfront.h" ^~~~~~~~~~~~ 1 error generated. error: command 'clang' failed with
阅读全文
摘要:delete FROM main_bussiness_cost1 where date is null; 不能用 date = null;
阅读全文
摘要:启动 进入后 修改timestamp格式 alter table table_name change `t1` TIMESTAMP(6) NOT NULL default '2000 01 01 00:00:00.00001';
阅读全文
摘要:1. brew install mysql 2. 启动mysql mysql.server start 我遇到了这个error,查openstack解决,我在这粘一下 ### Error:Can't connect to local MySQL server through socket homeb
阅读全文
摘要:'''SELECT date FROM `%s` ORDER BY date DESC LIMIT 1''' % 'ZXS-QZCSCRB-3'重点就是这个符号 ` 键盘左上角
阅读全文