Air RaidTime Limit:1000MSMemory Limit:10000KTotal
Submissions:6520Accepted:3877DescriptionConsider a town where all the streets
are one-way and each s...
分类:
其他好文 时间:
2014-06-06 23:19:59
阅读次数:
319
查看sqlserver被锁的表以及如何解锁查看被锁表:select
request_session_id spid,OBJECT_NAME(resource_associated_entity_id) tableName
from sys.dm_tran_locks where resourc...
分类:
数据库 时间:
2014-06-06 20:57:54
阅读次数:
274
1. /*+ALL_ROWS*/
表明对语句块选择基于开销的优化方法,并获得最佳吞吐量,使资源消耗最小化. 例如: SELECT /*+ALL+_ROWS*/
EMP_NO,EMP_NAM,DAT_IN FROM BSEMPMS WHERE EMP_NO=’SCOTT’; 2. /*+FIRST_R...
分类:
数据库 时间:
2014-06-06 18:24:51
阅读次数:
225
--减 就写成-1 --月 update 表 set
fhdate=DateAdd(M,-1,fhdate) where ...select dateadd(M,2,getdate()) --天数select
dateadd(day,2,getdate()) --年select dateadd(.....
分类:
其他好文 时间:
2014-06-06 15:11:58
阅读次数:
196
前面讲到的:insert … select … where not
exist其实好像也是为了实现:插入数据时,如果有重复则不插入。参见:http://snowolf.iteye.com/blog/1568926和INSERT
IGNORE INTO 差不多,不过前者可以自己加条件,后者只能根据主键...
分类:
数据库 时间:
2014-06-06 11:24:15
阅读次数:
327
问题描述:
Let d(n) be defined as the sum of proper divisors of n (numbers less than n which divide evenly into n).
If d(a) = b and d(b) = a, where a b, then a and b are
an amicable pair and each ...
分类:
编程语言 时间:
2014-06-02 12:31:42
阅读次数:
298
Scope defines where in a program a variable is accessible. Ruby has four types of variable scope, local, global, instance and class....
分类:
其他好文 时间:
2014-06-02 10:37:39
阅读次数:
241
Given a linked list, return the node where the
cycle begins. If there is no cycle, returnnull.Follow up:Can you solve it
without using extra space?借用博...
分类:
其他好文 时间:
2014-06-02 07:32:33
阅读次数:
291
经常写SQL语句的人应该知道Group by语句的主要用法是进行分类汇总,下面是一种它最常见的用法(根据部门、职位分别统计业绩):
SELECT a.dname,b.job,SUM(b.sal) sum_sal
FROM dept a,emp b
WHERE a.deptno = b.deptno
GROUP BY a.dname,b.job;
DNAME JOB...
分类:
数据库 时间:
2014-06-02 02:28:40
阅读次数:
289
SELECT * FROM msg_personchat_t WHERE send_userid='28' AND critime>'2014-03-30' AND critime...
分类:
数据库 时间:
2014-06-01 13:56:29
阅读次数:
210