- 浏览: 27665 次
最新评论
-
fishoflove:
怎么让索引自动同步?因为需要,但我对ORACLE TEXT 又 ...
oracle text performance
文章列表
disable script:
DECLARE
BEGIN
FOR i IN
(SELECT table_name,
constraint_name --disable first the foreign key
FROM user_constraints
WHERE constraint_type ='R'
AND status = 'ENABLED'
)
LOOP
EXECUTE IMMEDIATE 'alter table "' ||i.table_name|| '&quo ...
- 2009-06-12 13:35
- 浏览 4439
- 评论(0)
Replace Examples:
Date format change from dd.mm.yyyy to yyyy-mm-dd. This will turn the European date style 26.8.1994 or 26/8/1994 into 1994-8-26.
Search: ([0-9]{1,2}).([0-9]{1,2}).([0-9]{4})
Replace: $3-$2-$1
Find Examples:
(.)\1+ matches 'aaaa' and 'cc'. ...
- 2009-05-22 09:14
- 浏览 1018
- 评论(0)
USE [database name]
EXEC sp_MSforeachtable @command1="ALTER TABLE ? DISABLE TRIGGER ALL"
GO
EXEC sp_MSforeachtable @command1="ALTER TABLE ? NOCHECK CONSTRAINT ALL"
GO
Reference: http://www.sqlusa.com/bestpractices2005/disabletriggerconstraint/
- 2009-05-18 09:50
- 浏览 1166
- 评论(0)
DB2 is so hard to use, also its documentation... Even such a simple operation, it takes me much time...
Generally, char->varchar, smallint->integer, you can just modify the column through this sql:
alter table [table name] alter column [column name] set data type [new type]
But, if new colu ...
- 2009-05-11 08:56
- 浏览 2723
- 评论(0)
1. open cmd2. execute command "db2cmd"3. set trace on: db2 update monitor switches using statement on4. get snapshot: db2 get snapshot for dynamic sql on "database name" >> "d:\sql.txt"5. set trace off: db2 update monitor switches using statement off
- 2008-12-10 10:10
- 浏览 1016
- 评论(0)
Decorator, don't alter interface, but add resposibility. Adapter, convert one interface to another. Facade, make interface simpler.
- 2008-08-18 09:33
- 浏览 778
- 评论(0)
比如做一个wiki需要用的rich text editor,拿confluence和FCEditor为样本,需要有的基本功能:
undo redo find replace Insert table (Insert row, Delete row, Insert column, Delete column) Insert unordered list Insert ordered list Bold text Italic text Underline text StrikeThrough text Paragraph format Outdent Indent Insert link Ins ...
- 2008-07-28 08:18
- 浏览 1211
- 评论(0)
Specified that implementations running in a JSR-250 compliant container have their managed bean methods annotated with @PostConstruct be called after the object is instantiated, and after injection is performed, but before the bean is placed into scope. Specified that methods annotated with @PreDestr ...
- 2008-07-13 13:00
- 浏览 817
- 评论(0)
Problem description can be found here. A. Alien Numbers Follow is the solution:
public String getTargetNumber(String alienNumber,String srcLang,String targetLang) {
String ret = "";
// convert alienNumber to decimal number first
int decimalNumber = 0;
...
- 2008-07-11 07:23
- 浏览 984
- 评论(0)
CorporationSalary You can find the problem description here. Because the problem is little simple, so here change "If an employee has any subordinates, then his salary is equal to the sum of the salaries of his direct subordinates." as "If an employee has any subordinates, then his sal ...
- 2008-07-04 17:01
- 浏览 1439
- 评论(0)
list sort
- 博客分类:
- python study
Usage: list.sort([cmp[,key[,reverse]]])
how to use cmp parameter
def my_cmp(x,y):
if x<y:
return -1
elif x==y:
return 0
else:
return 1
arr = [2,5,3,1,4]
arr.sort(my_cmp)
print arr
Above example's result is [1,2,3,4,5];
how to use key parameter
arr = ['bj:beiji ...
- 2008-07-04 15:03
- 浏览 1198
- 评论(0)
看过的觉得还算可以的网络小说
- 博客分类:
- Books
全本的:裸兰善良的死神大唐行镖随波逐流之一代军师不死不灭佣兵天下正在更新的:
紫川
庆余年
师士传说异人傲世录神墓赫氏门徒
- 2008-06-26 08:51
- 浏览 777
- 评论(0)
如果有一个TYPE:
CREATE OR REPLACE type EMP_TYPE AS object
(
id NUMBER ,
name VARCHAR2 ,
birthday DATE ,
sex CHAR (1)
);
有一个Pacakge:
CREATE OR REPLACE PACKAGE EMP_UTIL IS
FUNCTION get_emp_by_id (p_id NUMBER) RETURN EMP_TYPE;
PROCEDURE create_emp (p_emp EM ...
- 2008-05-14 08:34
- 浏览 2355
- 评论(0)
oracle
text的索引跟其它的基本索引不同,当执行dml操作时,数据库不会自动维护这些索引(不过会将这些dml操作记录在表CTX_USER_PENDING里),需要调用存储过程ctx_dll.sync_index来维护索引。
当执行ctx_dll.sync_index时,会先去CTX_USER_PENDING表里查看未索引的行,然后将其索引。ctx_dll.sync_index能够利用多cpu的优势,并行执行。
Index Fragmentation
The CONTEXT index is an inverted index where each word contains
the ...
- 2008-03-17 13:12
- 浏览 1380
- 评论(1)
第一步需要先建一个oracle directory。
create directory TEMP_DIR as '/home/oracle/temp';
declare xml_str clob; xml_file Utl_File.file_type; offset NUMBER := 1; buffer varchar2(4000); buffer_size number := 2000;begin xml_file ...
- 2008-03-13 07:22
- 浏览 6364
- 评论(0)