DECLARE @T1 table(UserID int , UserName nvarchar(50),CityName nvarchar(50));insert into @T1 (UserID,UserName,CityName) values (1,'a','上海')insert into ...
分类:
数据库 时间:
2014-06-27 22:10:19
阅读次数:
385
Given a string containing only digits, restore it by returning all possible valid IP address combinations.For example:Given"25525511135",return["255.2...
分类:
其他好文 时间:
2014-06-26 00:07:07
阅读次数:
311
表中的数据被delete之后并不会真正删除数据,而是打了一个删除标记,只要还没有被覆盖就可以恢复回来。
实验过程如下:
SYS@ORCL>create table bbed_test(x varchar2(20));
Table created.
SYS@ORCL>insert into bbed_test values('BADLY9');
1 row created...
分类:
数据库 时间:
2014-06-22 22:06:59
阅读次数:
330
1.classmethods
such
as select/update/insert/delete queries。
# Example:
class User(Model):
username = CharField()
join_date = DateTimeField()
is_admin = BooleanField()
u = User(use...
分类:
编程语言 时间:
2014-06-22 21:27:39
阅读次数:
436
Given a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the given sum.
For example:
Given the below binary tree and sum...
分类:
其他好文 时间:
2014-06-22 20:59:24
阅读次数:
227
昨天在存储过程中用了语句insert into a select from b。在应用中发现bigint字段插入到int字段的时候,数值被截断了,插入后已经不是所要的值。因为存储过程中没有用到异常捕捉的处理,所以一开始并未发现错误,只是在比对数据的时候才发现不对。后来比对了两张表,才发现是字段类型不一样。接下来就试着验证了一下(window下的测试环境)。
创建两张表
CREATE T...
分类:
数据库 时间:
2014-06-22 17:57:28
阅读次数:
356
题目:Unique Binary Search Trees IIGivenn, generate all structurally uniqueBST's(binary search trees) that store values 1...n.For example,Givenn= 3, your...
分类:
其他好文 时间:
2014-06-22 13:49:21
阅读次数:
243
新增操作 insert函数会添加一个文档到集合里面。例如我们要登记一个人的信息,首先我们在shell力创建一个局部变量person,其记录了人的姓名和性别,我们通过db.persons.insert(person)想集合persons中插入一条记录,通过db.persons.findOne()查询刚...
分类:
数据库 时间:
2014-06-22 12:42:30
阅读次数:
250
散列表的实现常常叫做散列(hashing)。散列仅支持INSERT,SEARCH和DELETE操作,都是在常数平均时间执行的。需要元素间任何排序信息的操作将不会得到有效的支持。散列表是普通数组概念的推广。如果空间允许,可以提供一个数组,为每个可能的关键字保留一个位置,就可以运用直接寻址技术。当实际存...
分类:
编程语言 时间:
2014-06-22 10:55:33
阅读次数:
302
As we all know,a thread is a separate process on your computer.you can run multiple threads all at the same time.
multi-threaded code has the disadvantage of becoming quite complex very quickly,altho...
分类:
其他好文 时间:
2014-06-22 07:25:06
阅读次数:
244