【题目】
Given an unsorted integer array, find the first missing positive integer.
For example,
Given [1,2,0] return 3,
and [3,4,-1,1] return 2.
Your algorithm should run in O(n) time and uses constant space.
【题意】
给定一个数组,找出第一个缺失的正数。时间复杂度O(n)
...
分类:
其他好文 时间:
2014-05-21 17:13:07
阅读次数:
219
最近数据库从10.2.0.3升级到了10.2.0.5之后,一些对象无法编译通过。查看了这些对象主要表现在之前写法不严格的SQL语法导致了这些package无法成功编译,诸如select查询列中不能使用混淆的列名称等。另外一个比较表现突出的是返回ORA-00932: inconsistent datatypes: expected - got CLOB错误,即不一致的数据类型,获得CLOB数据类型。...
分类:
其他好文 时间:
2014-05-21 16:34:25
阅读次数:
434
利用PowerDesigner15在win7系统下对MySQL 进行反向工程
1、选择“数据库--》Generate Database...”,查看数据库表的SQL语句
2、找到“Preview”,查看SQL语句...
分类:
数据库 时间:
2014-05-21 11:35:19
阅读次数:
282
Description
In the Fibonacci integer sequence, F0 = 0, F1 = 1, and Fn = Fn ? 1 + Fn ? 2 for n ≥ 2. For example, the first ten terms of
the Fibonacci sequence are:
0, 1, 1, 2, 3, 5, 8, 13, 21, ...
分类:
其他好文 时间:
2014-05-21 09:39:15
阅读次数:
231
ALTER TABLE
sql-statement ::=
ALTER TABLE [database-name .] table-name alteration
alteration ::=
RENAME TO new-table-name
alteration ::=
ADD [COLUMN] column-def
SQLite...
分类:
数据库 时间:
2014-05-21 08:10:45
阅读次数:
344
一、Backup and Recovery Overview
1、Backup and Recovery Overview
1.1 What is Backup and Recovery?
一般,备份和恢复引用各个策略和过程保护你的数据库背离数据丢失,同时在任何一种数据丢失后重建数据库。
1.1.1 Physical Backups and Logical Backups
一个备份是...
分类:
数据库 时间:
2014-05-21 07:55:51
阅读次数:
376
前些时候,同事在站点服务端使用SQlite存储一些临时数据,但是在多人并发的时候Sqlite会抛出异常:The database file is locked , database is locked,而且这个是在客户生产环境下提示出来的,开发环境很难重现,同事实在没辙,竟然想发动所有研发同事通过操作软件重现问题,我只能呵呵了。既然是Sqlite的原因,直接写个小程序测试下sqlite不就行了,而...
分类:
数据库 时间:
2014-05-21 07:13:51
阅读次数:
483
借助field_for可以生成表单来处理两个或更多模型对象的数据先看一个官方的例子,一个表单中有person和permission两个模型,其中每个person包含一个permission
First name: Last name: Admin : ...
Given an array of non-negative integers, you
are initially positioned at the first index of the array.Each element in the
array represents your maximu...
分类:
其他好文 时间:
2014-05-21 04:39:53
阅读次数:
332
File error 3219 occurs on Microsoft SQL servers
where you are attempting to improperly restore a database with the "Restore
Files and Filegroups" comm...
分类:
数据库 时间:
2014-05-21 03:36:02
阅读次数:
427