10 2015 档案

摘要:解析oracle的rownum 本人最近在使用oracle的rownum实现分页显示的时候,对rownum做了进一步的分析和研究。现归纳如下,希望能给大家带来收获。 对于rownum来说它是oracle系统顺序分配为从查询返回的行的编号,返回的第一行分配的是1,第二行是2,依此类推,这个伪字段可以用... 阅读全文
posted @ 2015-10-30 18:53 老趙 阅读(161) 评论(0) 推荐(0)
摘要:create or replace procedure pr_mytest isv_test number(8);--变量v_char varchar2(10);c_changl constant number (12,3):= 3.14;--常量v_bm t_hq_ryxx.bumbm%type;... 阅读全文
posted @ 2015-10-30 16:55 老趙 阅读(178) 评论(0) 推荐(0)
摘要:--数字型函数select abs (-100) from dual;--绝对值select mod (10,3) from dual;--求模select ceil (12.5) from dual;--取上限整数select floor (12.5) from dual;--取下限整数selec... 阅读全文
posted @ 2015-10-29 17:07 老趙 阅读(375) 评论(0) 推荐(0)
摘要:--内连接 两种写法 等值连接select r.*,b.bummc from t_hq_ryxx r, t_hq_bm b where r.bumbm = b.bumbmselect r.*,b.bummc from t_hq_ryxx r inner join t_hq_bm b on r.bum... 阅读全文
posted @ 2015-10-29 17:06 老趙 阅读(228) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2015-10-28 14:33 老趙 阅读(149) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2015-10-28 09:42 老趙 阅读(194) 评论(0) 推荐(0)
摘要:建表 阅读全文
posted @ 2015-10-27 19:48 老趙 阅读(169) 评论(0) 推荐(0)
摘要:--查询全表select * from t_hq_ryxx;--查询字段select xingm as 姓名 ,gongz as 工资 from t_hq_ryxx;--链接字段查询select xingm || xingb as 姓名性别 from t_hq_ryxx--去除重复查询select ... 阅读全文
posted @ 2015-10-27 16:29 老趙 阅读(174) 评论(0) 推荐(0)
摘要://创建一个名为TEST1的表空间CREATE SMALLFILE TABLESPACE "TEST1" DATAFILE 'G:\ORACLE_11G\ORADATA\ORCL\TEST1' SIZE 100M AUTOEXTEND ON NEXT 10M MAXSIZE UNLIMITED LO... 阅读全文
posted @ 2015-10-27 09:36 老趙 阅读(260) 评论(0) 推荐(0)
摘要:--创建表T_HQ_BM2--create table t_hq_bm2 as select * from t_hq_bm;commit;--添加行内容--insert into t_hq_bm2 values ('105','宣传部','22222222');commit;--删除部门编码为105... 阅读全文
posted @ 2015-10-27 09:31 老趙 阅读(159) 评论(0) 推荐(0)
摘要:Oracle PL/SQL入门之慨述一、PL/SQL出现的目的 结构化查询语言(Structured Query Language,简称SQL)是用来访问关系型数据库一种通用语言,它属于第四代语言(4GL),其执行特点是非过程化,即不用指明执行的具体方法和途径,而是简单的调用相应语句来直接取得结果... 阅读全文
posted @ 2015-10-22 17:00 老趙 阅读(159) 评论(0) 推荐(0)
摘要:package jihe;public class Emp { private String id; private String name; public String getId() { return id; } publ... 阅读全文
posted @ 2015-10-17 08:42 老趙 阅读(121) 评论(0) 推荐(0)
摘要:Set hs = new HashSet(); hs.add("A"); hs.add("a"); hs.add("c"); hs.add("C"); hs.add("a"); for... 阅读全文
posted @ 2015-10-16 19:43 老趙 阅读(90) 评论(0) 推荐(0)
摘要:package jihe;import java.util.ArrayList;import java.util.List;public class xitizuoye { public static void main(String[] args) { List... 阅读全文
posted @ 2015-10-16 19:28 老趙 阅读(135) 评论(0) 推荐(0)
摘要:第三题package xin_learn;import org.omg.Messaging.SyncScopeHelper;class grandfather { public grandfather() { System.out.println("爷爷"); }}c... 阅读全文
posted @ 2015-10-15 18:53 老趙 阅读(214) 评论(0) 推荐(0)
摘要:package learn;import java.util.Random;public class yanzhengma { public static void main(String[] args) { // TODO Auto-generated method stub ... 阅读全文
posted @ 2015-10-13 08:54 老趙 阅读(146) 评论(0) 推荐(0)
摘要://九九乘法表 作业 for(int c =1; c< 10; c++) { for(int a =1; a < c + 1 ; a++) { if(a < 10) ... 阅读全文
posted @ 2015-10-10 11:00 老趙 阅读(225) 评论(1) 推荐(0)
摘要://一维数组 int myarry[] = new int [5]; //索引是从0开始 myarry[0] = 100; myarry[2] = 200; //初始化 int arry[] = new int[]{1,2,3,4,5}; ... 阅读全文
posted @ 2015-10-09 15:00 老趙 阅读(371) 评论(0) 推荐(0)
摘要://升序排序 int sz []= {3,45,33,68,73,98,16,28}; for (int a : sz ) { System.out.print (a + " "); } ... 阅读全文
posted @ 2015-10-09 14:59 老趙 阅读(368) 评论(0) 推荐(0)
摘要:定义: 二分查找又称折半查找,优点是比较次数少,查找速度快,平均性能好;其缺点是要求待查表为有序表,且插入删除困难。因此,折半查找方法适用于不经常变动而查找频繁的有序列表。首先,假设表中元素是按升序排列,将表中间位置记录的关键字与查找关键字比较,如果两者相等,则查找成功;否则利用中间位置记录将表分... 阅读全文
posted @ 2015-10-09 14:20 老趙 阅读(175) 评论(0) 推荐(0)
摘要:double a1 = 0 ,b2 = 1; int n = 1; while( n <= 20 ) { b2 = b2 * n++; a1 = a1 + 1 / b2; ... 阅读全文
posted @ 2015-10-07 19:57 老趙 阅读(1393) 评论(0) 推荐(0)
摘要:int a = 0, b = 1, d = 1, c = 6, e = 1; for( b = 1; b <= c; b ++) { do { ... 阅读全文
posted @ 2015-10-07 19:45 老趙 阅读(213) 评论(0) 推荐(0)
摘要:int i,j; for( i = 1; i <= 4; i ++) { for( j = 1; j <= 4 - i; j++) System.out.print(" "); ... 阅读全文
posted @ 2015-10-07 19:36 老趙 阅读(338) 评论(0) 推荐(0)