摘要:
问题:用 android 4.4 写android访问http时,到connection.getResponseCode() 就不被执行,也不报错:但是抛出org.json.JSONException: End of input at character 0 of .异常:连接代码:public s... 阅读全文
摘要:
declare v_rowcount integer; v_rowcount1 integer; v_rowcount2 integer;begin select count(*) into v_rowcount from dual where exists( select * from col w... 阅读全文
摘要:
由于存在不是整周,和起始日期,终止日期星期不定的复杂情况,所以简单的sql语句貌似无法实现.写个函数,从起始日期开始,判断不是周末的话就加1天,只到终止日期.create or replace function day_count(t1 date,t2 date) return numberis n number:=0;tt date;begin tt:=t1; while tt<=t2 loop n:=n+(case when to_char(tt,'day') in('星期六','星期日') then 0 else 1 end); tt 阅读全文
摘要:
--例如 with a as ( select 'a' A, 'b' B ,5 C ,2 D from dual union all select 'w', 'b', 1, 3 from dual union all select 'x' ,'x' ,3 ,1 from dual ) select decode(grouping(A),1,'合計',A) A ,B,sum(C) C,SUM(D) D from a group by rollup ((a,b))create table 阅读全文
摘要:
需求说明: 需要查询出某个客户某一年那些天是有连续办理过业务实现SQL如下: 创建表: create table test_num(tyear number, tdate date); 测试数据:insert into test_numselect 2014,trunc(sysdate)-1 from dual union all select 2014,trunc(sysdate)-002 from dual union all select 2014,trunc(sysdate)-003 from dual union all select 2014,trunc(sysdate)-004 阅读全文