查询smp_db数据库中所有的数据表INFORMATION_SCHEMA.TABLESselect TABLE_NAME from INFORMATION_SCHEMA.TABLES where TABLE_SCHEMA='smp_db'查询smp_db数据库中smp_import_db表所有的字段...
分类:
数据库 时间:
2016-01-26 10:41:30
阅读次数:
165
mysql表中datetime类型的字段名createtime,查询所有createtime为空的语句如下:select * from yy_business where ISNULL(createtime) is TRUEupdate yy_business set createtime='201...
分类:
数据库 时间:
2016-01-25 22:52:46
阅读次数:
306
今天:Select * From log Where to_days(cdate) = to_days(now());昨天:Select * From log Where to_days( NOW( ) ) - to_days(cdate) <= 1近7天:Select * From log Whe...
分类:
其他好文 时间:
2016-01-25 17:12:11
阅读次数:
173
--递归查询产品分类 WITH cte AS ( SELECT * FROM syn_Categories WHERE id = $CategoryID$ UNION ALL SELECT syn_Categories....
分类:
数据库 时间:
2016-01-25 17:01:46
阅读次数:
143
In the context of a hash table, the term "collision" is usually used for the situation where twounequalkeys have the same hash code. They still need t...
分类:
其他好文 时间:
2016-01-25 13:00:24
阅读次数:
113
show databases;use nxu_life;show tables;select * from news where department='教务处' limit 10,10;set names gb2312;show columns from news;drop database nx...
分类:
数据库 时间:
2016-01-25 08:47:11
阅读次数:
175
删除表,先猜表名,可以使用下面的语名:Select * from A where A.a = ‘testdata’; drop table A---’; If a field only allow number, give it a String or others 假如一个字段仅仅只允许使用...
分类:
数据库 时间:
2016-01-24 23:49:02
阅读次数:
212
理解TOP子句众所周知,TOP子句可以通过控制返回行的数量来影响查询。我们知道TOP子句能很容易的满足返回指定行数的子集,接下来有一些例子来展示什么情况下使用TOP子句来返回一个结果集;你打算返回的恰好是一个记录的子集来验证你代码;你仅仅需要确定至少一行数据满足特定的Where条件;你的业务需求指示...
分类:
数据库 时间:
2016-01-24 23:44:59
阅读次数:
309
遇到一坑:对于如下代码select * from order_mileagefuel where date > '2015-11-1' and date character varying解决方法:将String类型的参数改为java.sql.Timestamp
分类:
数据库 时间:
2016-01-24 19:44:04
阅读次数:
439
Longest PrefixIOI'96The structure of some biological objects is represented by the sequence of their constituents, where each part is denoted by an up...
分类:
其他好文 时间:
2016-01-24 11:31:23
阅读次数:
109