博文

目前显示的是 一月, 2016的博文

Getting Started with Underscore.js

http://www.sitepoint.com/getting-started-with-underscore-js/

Efficient SQL Statements in Oracle

1. not in A: SELECT col1,col2,col3 FROM table1 a WHERE a.col1 not in (SELECT col1 FROM table2) B:SELECT col1,col2,col3 FROM table1 a WHERE not exists (SELECT 'x' FROM table2 b WHERE a.col1=b.col1) B:  is better than A. a<>0  to->  a>0 or a<0 a<>''  to->  a>'' 2. not null a>0 or a>'' is better than a is not null. 3.>= replace > A: SELECT … FROM DEPARTMENT WHERE DEPT_CODE >=0; B: SELECT * FROM EMP WHERE DEPTNO >3 A is better than B. 4.LIKE name LIKE '%jeck%'  should be name LIKE 'Xjeck%' OR YY_BH LIKE 'Bjack%' 5.EXISTS v DISTINCT A: SELECT DISTINCT DEPT_NO,DEPT_NAME FROM DEPT D , EMP E WHERE D.DEPT_NO = E.DEPT_NO B: SELECT DEPT_NO,DEPT_NAME FROM DEPT D WHERE EXISTS (SELECT 'X' FROM EMP E WHERE E.DEPT_NO = D.DEPT_NO); B is better than A 6. page A: select *   from (select a.*, rownum as rnum           from (select * from table1) a          where rownum <

Datepicker z-index issue?

http://jqueryui.com/download/ Ref: http://stackoverflow.com/questions/11533161/jquery-ui-datepicker-change-z-index Solution:     var date2 = $( "#end_date" ).datepicker({    defaultDate: new Date(),    changeMonth: true ,    numberOfMonths: 1,    minDate: lastYear,    dateFormat: 'yy-mm-dd' ,    beforeShow: function () {        setTimeout( function (){             $( '.ui-datepicker' ).css( 'z-index' , 99999999999999);        }, 0);    }  });

Interface in Java 8

1.Default Methods in Interfaces Java 8 introduced a new keyword default. Now you’re allowed to write a default implementation of a method in the interface. Such a method won’t be considered abstract anymore, and you won’t be forced to implement it in your class. 2.Static Methods in Interfaces Starting from Java 8, interfaces are also allowed to include static methods, which are not specific to any instance and can be used only internally by other methods of the interface. public interface testInter { public void test1 ( int i ); public default void test2 ( int i ){ System . out . println ( "Default Method!" ); if(isJUNE()){System.out.println("There is a Static Method.");}  }; //S tatic Method,which are not specific to any instance //and can be used only internally by other methods of the interface. static boolean is JUNE (){ Month month = LocalDate . now (). getMonth (); if ( month