Mysql 4.X ?? ------SHOW TABLE STATUS FROM [DB_NAME] LIKE '[TABLE_NAME]';=> ???? ???? Auto_increment ??? ??Mysql 5.X -----------SELECT AUTO_INCREMENT F...
分类:
其他好文 时间:
2015-06-30 21:42:54
阅读次数:
112
-- 统计三月的每天的数据量select count(*),substr(t.date,1,10) from table t where t.date like '2010-03%' group by substr(t.date,1,10) ;--统计从5月19到6月29的数据量SELECT sub...
分类:
数据库 时间:
2015-06-30 12:42:04
阅读次数:
164
Say you have an array for which the ith element is the price of a given stock on day i.Design an algorithm to find the maximum profit. You may complete as many transactions as you like (ie, buy one and...
分类:
其他好文 时间:
2015-06-30 10:32:15
阅读次数:
120
题目要求:The string"PAYPALISHIRING"is written in a zigzag pattern on a given number of rows like this: (you may want to display this pattern in a fixed fo...
分类:
其他好文 时间:
2015-06-29 22:16:15
阅读次数:
191
MySQL5.5以后默认使用InnoDB存储引擎,其中InnoDB和BDB提供事务安全表,其它存储引擎都是非事务安全表。若要修改默认引擎,可以修改配置文件中的default-storage-engine。可以通过:show variables like 'default_storage_engine...
分类:
数据库 时间:
2015-06-29 19:56:30
阅读次数:
147
Well , you know. As a college student who want to find a good job after graduating like me , scores are not that important. I just want to have some ....
分类:
其他好文 时间:
2015-06-29 13:07:28
阅读次数:
113
B-Tree索引/位图索引/反向索引/函数索引/降序索引/分区索引oracle导致索引失效的情况1、使用不等于操作符2、使用is null或is not null3、使用函数4、比较不匹配的数据类型5、复合索引中的前导列没有被作为查询条件6、查询的数量是大表的大部分7、对小表查询8、like "%_...
分类:
其他好文 时间:
2015-06-28 18:49:29
阅读次数:
129
1 CREATE TABLE A LIKE B此种方式在将表B复制到A时候会将表B完整的字段结构和索引复制到表A中来。2. CREATE TABLE A AS SELECT * FROM B此种方式只会将表B的字段结构复制到表A中来,但不会复制表B中的索引到表A中来。这种方式比较灵活可以在复制原表....
分类:
数据库 时间:
2015-06-28 16:55:30
阅读次数:
162
乱码分析:
首先在cmd窗口下,一个cmd窗口就是一个客户端,默认是使用gbk编码的,但是这个编码是不可以更改的。
当输入汉字"张"的时候客户端使用gbk进行编码:假设 张:1110
服务器使用什么解码的?我们使用show variables like "character%";打印结果如下:
解释:
-----+
| Variable_name | Val...
分类:
数据库 时间:
2015-06-28 09:55:18
阅读次数:
192
上一篇总结了mergeSort-like questions,这篇总结一下有关quickSort的问题。Question:Given an array of object A, and an array of object B. All A's havedifferent sizes, and al...
分类:
其他好文 时间:
2015-06-28 06:27:16
阅读次数:
110