The different between NULL and ''
We can insert NULL into a column of a table.There are two examples,let's see the difference.1、INSERT INTO table_name VALUES( id,NULL);This method inserts NULL to a column of the table. 2、INSERT INTO table_name VALUES( id,'');This method doesn't insert NULL into the column ofthe table,because '' is a valid value,though it is a empty string.[@more@]
The different between DELETE TABLE AND TRUNCATE TABLE
TRUNCATE is faster than DELETE ,because it doesn't make a note of the change of the data.[@more@]
The usage of INSTR()
INSTR(表的某个字段,'外部传入的值') 1、INSTR(c1,c2[,n1[,n2]]) 返回c2在c1中位置l c2:要寻找的字符串l n2:第几个匹配项。大于0例如: INSTR(,,-) DUAL;[@more@]
About the REPORT name
If the report filename is test.rdf ,but the report name is test_1,then the complied report filename is test_1.rep.[@more@]
The usage of Union & Union All
1、UNION 中的每个查询必须包含相同的列、表达式或聚集函数(不过各个列不需要以相同的次序列出)2、列数据类型必须兼容:类型不必完全相同,但必须是DBMS可以隐含转换的类型(例如不同的数值类型或不同的日期类型)The following script gives some examples.[@more@]SQL> COLUMN cust_name FORMAT A20SQL> COLUMN cust_contact FORMAT A20SQL> COLUMN cust_email FORMAT A25SQL> SELECT cust_name,cust_contact,cust_email FROM customers;CUST_NAME CUST_CONTACT CUST_EMAIL -------------------- -------------------- ------
DISTINCT AND AVG()
If you use AVG() with distinct ,it will raise the average value.[@more@]
The usage of NULL with function
You can see the usage of NULL with function by the following scripts.FUNCTION:AVG()、COUNT()、SUM() AVG(): It doesn't consider the column which is null.If the record has 5 rows,the specified column has 3 real values and 2 null values,the AVG equals: the summmary of the 3 real value divied 3.(not 5)COUNT():It doesn't consider the column which is null.If the record has 5 rows,the specified column has 3 real values and 2 null values,the count equals:3(not 5)SUM():It doesn't consider the column whic
FORM 6i 安装
很久没有安装过FORM了,因为自己电脑基本半个月做一次GHOST,所以,常用的软件,很少会安装多次,这几日,自己的同事,被FORM的安装折腾的够呛,后来将瑞星给卸掉,再安装,就很顺利,在此,想给安装FORM6i的朋友提个醒,如果安装过程中,出现问题,请检查一下,是不是杀毒软件在作怪。[@more@]
One DOS command!
One DOS batch command can copy a source dir to object dir which will be auto named by the current date.[@more@]/**************************************************Creator: Eric Zhao(English name)Zhaofei(Chinese name)Date: 2007-11-08Object: Copy a source dir to object dir which willbe auto named by the current date.source dir: D:1object dir: D:%date:~0,4%%date:~5,2%%date:~8,2%--The following command is the batch command.@echo offxcopy D:1 D:%date:~0,4%%date:~5,2%%date:~8,2%echo exit;**************
对齐!
一直,以来对FORM 中对齐方式的“堆叠”和“分布",不太清楚怎么用,今天一同事,指点一下,豁然开朗!堆叠:水平选“堆叠”,垂直选“顶部对齐”;节省了不少时间![@more@]
About Tuning the SQL clause!
I don't think I konw how to tuning the SQL clause,and the following is a example ,and in the future ,I will add more![@more@]--Before we see the example,I will first declare sth about the --table A and B;--A.column1 don't have a index--B.column2 is the primark key of table B--1SELECT * FROM A,BWHERE A.column1=B.column2--2SELECT * FROM A,BWHERE B.column2=A.column1--3SELECT * FROM A,BWHERE SUBSTR(B.column2,1,2)=A.column1--Frankly speaking ,I am nou quite sure about the method to --see the time for
How to use the
The following will show you how to use the explain plan:[@more@]--通过以下方法可以把Autotrace的权限授予Everyone,--如果你需要限制Autotrace权限,可以把对public的授权改为对特定user的授权。 connect sys as sysdba@E:oracle10.2.0db_1RDBMSADMINutlxplan--create public synonym plan_table for plan_table;grant all on plan_table to public ;@E:oracle10.2.0db_1sqlplusadminplustrce/*drop role plustrace;create role plustrace;grant select on v_$sesstat to plustrace;grant select on v_$statname to plustrace;grant
How to copy a table from the remote database!
The following is showing how to copy a table from a remote database:[@more@]First ,you should use an exsited user or create a new user,and grant create database link priveledge to the user: CREATE USER JRZBIDENTIFIED BY JRZBDEFAULT TABLESPACE USERSTEMPORARY TABLESPACE TEMPQUOTA 50M ON USERSACCOUNT UNLOCK;----GRANT SYSDBA TO Test_Eric;--DESC DBA_TAB_PRIVS;--SELECT PRIVILEGE FROM DBA_SYS_PRIVS-- WHERE GRANTEE='JRZB';GRANT ALTER SYSTEM TO JRZB;GRANT ALTER DATABASE TO JRZB;GRANT CREATE SESSION TO JR
CREATE USER!
You can see how to create a user;[@more@]CREATE USER Test_EricIDENTIFIED BY ERICDEFAULT TABLESPACE USERSTEMPORARY TABLESPACE TEMPQUOTA 5M ON USERSACCOUNT UNLOCK;----GRANT SYSDBA TO Test_Eric;--DESC DBA_TAB_PRIVS;--SELECT PRIVILEGE FROM DBA_SYS_PRIVS-- WHERE GRANTEE='JRZB';GRANT ALTER SYSTEM TO Test_Eric;GRANT ALTER DATABASE TO Test_Eric;GRANT CREATE SESSION TO Test_Eric;GRANT CREATE TABLE TO Test_Eric;GRANT ALTER ANY TABLE TO Test_Eric;
:system.form_status
:system.form_statusp.s http://www.itpub.net/61129.html[@more@]系统变量:system.form_status代表了form的状态:'CHANGED', 'NEW', 'QUERY'。按下默认[exit]键或选择默认菜单中的exit项时,程序执行的是do_key('KEY-EXIT')。如果没有自定义key-exit触发器,do_key('KEY-EXIT')调用key-exit对应的默认built-in过程: exit_form。exit_form实际上有三个重载过程:exit_form; exit_form(commit_mode);exit_form(commit_mode, rollback_mode);exit_form等于exit_form(ASK_COMMIT)。它将检查system.form_status,如果不为'QUERY',弹出对话框提
See the constraint properrty of a table!
ex:SELECT CONSTRAINT_NAME FROM USER_CONSTRAINT_NAMEWHERE TABLE_NAME=' '; [@more@]
What does the Forms & Reports 6i Patch 18 for Windows need to be noticed?
1、 P18补丁中,文本项属性多了一项:"锁定记录",每次一定要把其设定为:‘否’;2、注意列表项也具有此属性,只是被隐藏起来了,需要先把列表项改为文本项,将这一属性设置为‘否’,然后再改回为列表项;3、B/S模式下的某些按钮字体设为8 ,字体一般设置为罗马西方字体,字号为8号,方便显示。[@more@]