1.最近因为写J2EE版本的书店管理系统,碰到了模糊查询的问题;因为我查询的关键字是中文,导致刚开始出现了很多问题;ResultSet rs-> 比如: select * from book where bookName = '操作系统';明明这条语句是可以在mysql数据库中查到的,但是 rs.next()却始终未false;这很奇怪,我唯一能想到的原因就是中文乱码问题;果然经过查阅资料;找到了...
分类:
数据库 时间:
2015-06-13 09:52:54
阅读次数:
153
1.待改写语句如下update table1 f set f.ljjine1= (select nvl(sum(nvl(b.jine1,0)),0) from table1 b where b.kjqj<=f.kjqj and b.gs=f.gs and b.bm=f.bm and b...
分类:
数据库 时间:
2015-06-12 23:50:37
阅读次数:
211
Problem Description:Given a binary tree where all the right nodes are either leaf nodes with a sibling (a left node that shares the same parent node) ...
分类:
其他好文 时间:
2015-06-12 23:47:36
阅读次数:
159
1.不同数据库之间复制表的数据的方法:当表目标表存在时:insert into 目的数据库..表 select * from 源数据库..表当目标表不存在时:select * into 目的数据库..表 from 源数据库..表2. 查看是否锁表show OPEN TABLES where In_u...
分类:
数据库 时间:
2015-06-12 23:45:50
阅读次数:
172
自定义调用 ecshop分页代码原文出处:http://blog.sina.com.cn/s/blog_6479ae370100hsq6.htmlfunction get_comments($num,$start){$sql =" SELECT * FROM ecs_comment WHERE st...
分类:
其他好文 时间:
2015-06-12 19:17:24
阅读次数:
341
一、什么时候可以避免执行MapReduce?select *where语句中只有分区字段二、Jion优化驱动表最右边查询表表的大小从左边到右边依次增大标志机制显示的告知查询优化器哪张表示大表/*+streamtable(table_name)*/三、Map-side聚合sethive.map.agg...
分类:
其他好文 时间:
2015-06-12 19:14:16
阅读次数:
223
在使用全文索引的时候例如:SELECT [PRID] ,[PRCode] ,[PRDesc] FROM [test1].[dbo].[PerformanceIssue] where contains([PRDesc],'。。。');。。。这里必须填写有含义的次,比如(蓝天,水,...
分类:
数据库 时间:
2015-06-12 18:56:13
阅读次数:
152
一、什么时候可以避免执行MapReduce?select *where语句中只有分区字段 二、Jion优化驱动表最右边查询表表的大小从左边到右边依次增大标志机制显示的告知查询优化器哪张表示大表/*+streamtable(table_name)*/ 三、...
分类:
其他好文 时间:
2015-06-12 17:34:37
阅读次数:
123
一、什么时候可以避免执行MapReduce?select
*where语句中只有分区字段
二、Jion优化驱动表最右边查询表表的大小从左边到右边依次增大标志机制显示的告知查询优化器哪张表示大表/*+streamtable(table_name)*/
三、Map-side聚合sethive.map.aggr=true;这个设置可以将顶层的聚合操作放在Map阶段执行,从而减轻清洗...
分类:
其他好文 时间:
2015-06-12 17:24:34
阅读次数:
174
Given a binary tree and a sum, find all root-to-leaf paths where each path’s sum equals the given sum.For example:
Given the below binary tree and sum = 22, 5
/ \...
分类:
其他好文 时间:
2015-06-12 17:17:40
阅读次数:
84