`
文章列表
hibernate按照insert,update,----- delete的顺序提交所有登记的操作。 例子: Cat  cat  =  new  Cat(); cat.setName(“tom”); s.save(cat);   cat.setName(“mary”); s.update(cat);   Cat  littleCat = new  Cat(); littleCat.setName(“tom”); s.save(littleCat);   s.flush();   会报主键冲突, s.save(littleCat);将在 s.update(cat) ...
如果您想要在自己所定义的Servlet类别中使用Spring的容器功能,则也可以使用 org.springframework.web.context.ContextLoaderListener,例如在web.xml中使用< listener>标签加以定义:...<listener><listener-class>org.springframework.web.context.ContextLoaderListener</listener-class></listener>...ContextLoaderListener预设会读取appl ...
写道 通过xml配置文件 bean配置在xml里面,spring提供多种方式读取配置文件得到ApplicationContext. 第一种方式:FileSystemXmlApplicationContext 通过程序在初始化的时候,导入Bean配置文件,然后得到Bean实例: ApplicationContext ac = new FileSystemXmlApplicationContext("applicationContext.xml") ac.getBean("beanName"); 第二种方式:WebApplicationContextUtil ...
写道 web.xml 中的listener、 filter、servlet 加载顺序及其详解12011-02-13 15:20 web.xml 中的listener、 filter、servlet 加载顺序及其详解 一、概述 1、启动一个WEB项目的时候,WEB容器会去读取它的配置文件web.xml,读取<listener>和<context-param>两个结点。 2、紧急着,容创建一个ServletContext(servlet上下文),这个web项目的所有部分都将共享这个上下文。 3、容器将<context-param>转换为键值对,并交给servle ...

Filter

chain.doFilter(request,response) <!-- 正文开始 --> 他的作用是将请求转发给过滤器链上下一个对象。这里的“下”指的是哪里 ? 值得是下一个filter,如果没有filter那就是你请求的资源。  一般filter都是一个链,web.xml 里面配置了几个就有几个。一个一个的连在一起  request -> filter1 -> filter2 ->filter3 -> .... -> request resource. 下面举一个例子: input.jsp是用来提交输入的,当提交后,过 ...
<script type="text/javascript"></script> weblogic.management.ManagementException 出现这个异常There are 1 nested errors: weblogic.management.ManagementException: [Management:141266]Parsing Failure in config.xml: javax.xml.namespace.QName; local class incompatible: stream clas ...
用法实例如下:   select   decode(x,1,'x is 1',2,'x is  2','others')  from  dual     当x  是1 时,则返回 ‘x  is 1’   当 x 是2 时,则返回 ‘x  is 2’   否则的话,则返回 ‘others’     再如:   a  表按照语数外进行排序     select  *  from   a  order  by  decode(km,'语文',1,'数学',2,'外语',3)   这样就可以排序了

oracle意外drop表

http://8xybuttfly.blog.163.com/blog/static/31544631200921622243659/   只需要一条语句就可以从闪存中找回来   SQL> FLASHBACK TABLE AKM TO BEFORE DROP;

js确认删除框

 
if(confirm('确实要删除吗?')){   确定删除后所作的。   }

div滚动条

<div style ="overflow:auto;width:100%;height:450px"> <table></table> </div>

decode函数

select decode( x , 1 , ‘x is 1 ’, 2 , ‘x is 2 ’, ‘others’) from dual   当x等于1时,则返回‘x is 1’。   当x等于2时,则返回‘x is 2’。   否则,返回others’。

plsql对小时判断

if  to_char(sysdate,'HH24')   not  between  '9'   and  '17'   then
项目中遇到,遂从网上搜索了下,觉得如下解释较为通俗易懂:   假设oracle有以下两个用户: admin , visitor 我们在admin下建立了 testtable 这个表,并且对visitor用户赋权 然后我们用visitor登陆 : 查询这个表的时候我们一定需要这样写 select * from admin.testtable 如果直接写 select * from testtable oracle会报错说表不存在 但是我们可以在visitor里建立[私有同义词] 让 testtable = admin.testtable 这样在visitor下就可以直接输入 ...

jquery的html()

jquery中美元符号命名冲突,项目中遇到$('#tt').html()  不起作用   搜索碰到一篇文章  http://www.cnblogs.com/mahaisong/archive/2011/06/05/2073129.html  解释较详细,   但是按照方法并没有解决我的问题:   最后改为按照js方式取数:     document.getElementById("tt").innerHTML;   $('#tt').html()    这两种方式都可以。
用ajax把table中的内容传到后台,但是试了几种方法ajax不会调用后台,才发现是请求参数值过长导致。   下面是解决方案:   修改使用的XMLHTTP的请求为POST,并且把参数和URL分离出来提交     function sAjaxRequest(){ var  record = save_record(); xmlRequest = getXMLHttpRequestObject(); alert("xmlRequest"+xmlRequest); if(xmlRequest==null){  alert("您的浏览器不支持AJAX!&q ...
Global site tag (gtag.js) - Google Analytics