摘要:1, 在web.xml中定义 contextConfigLocation参数.spring会使用这个参数加载.所有逗号分割的xml.如果没有这个参数,spring默认加载web-inf/applicationContext.xml文件.<context-param><param-name>contextConfigLocation</param-name><param-value>classpath*:conf/spring/applicationContext_core*.xml,classpath*:conf/spring/applicati
阅读全文
摘要:1, 在web.xml中定义 contextConfigLocation参数.spring会使用这个参数加载.所有逗号分割的xml.如果没有这个参数,spring默认加载web-inf/applicationContext.xml文件.<context-param><param-name>contextConfigLocation</param-name><param-value>classpath*:conf/spring/applicationContext_core*.xml,classpath*:conf/spring/applicati
阅读全文
摘要:其面我们介绍了创建外键约束时如果使用oracle默认的创建方式,在删除被参照的数据时,将无法被删除,这一点在oracle9i中给了我们更多灵活的选择,我们可是使用on delete cascade和 on delete set null关键字来决定删除被参照数据时是否要将参照这个数据的那些数据一并删除,还是将那些参照这条数据的数据的对应值赋空。例如下面这两个表中分别存的时员工的基本信息和公司的部门信息。我们为create table dept(deptno number(10) not null,deptname varchar2(30) not null,constraint pk_dept
阅读全文
摘要:书上说该方法能够加载类,于是我写了如下的一个程序class Gum{ static { System.out.print("Loading Gum"); }}public class SweetShop { public static void main(String args[]){ try{ Class.forName("Gum"); }catch(ClassNotFoundException e){ System.out.print("Couldn't find Gum"); } }}程序输出是:Couldn't
阅读全文
摘要:SQL> editWrote file afiedt.buf40我的sqlplus刚开始使用edit命令时会如上面所示,我把vi设置为默认编辑器后就没问题了:SQL> set _EDITOR=viSQL> ed但这样我设置只是会话设置,以重新登陆后就会失效。如果想不劳永逸,你还可以把编辑器设置存到配置文件,每次自动使用该配置。修改$ORACLE_HOME/sqlplus/admin/glogin.sql配置文件,增加define _editor=vi即可,sqlplus启动的时候会读取glogin.sql脚本。在Linux的sqlplus中,如果使用edit对当前脚本进行编辑
阅读全文