oracle
阿钿_
这个作者很懒,什么都没留下…
展开
-
简单的PL/SQL
Declare person_id_v Number(10) :=70; full_name_v Varchar2(240) ;Begin Select full_name Into full_name_v From hr.per_all_people_f Where person_id = person_id_v; ...2006-12-20 22:05:49 · 86 阅读 · 0 评论 -
PL/SQL 循环 1
Declare counter Binary_Integer :=1; Begin Loop Insert Into test Values('aa',counter); counter := counter+1; If counter >10 Then Exit; End If; End Lo...2006-12-20 22:17:18 · 86 阅读 · 0 评论 -
PL/SQL 循环 WHILE
Declare counter Binary_Integer :=40; Begin While counter2006-12-20 22:25:18 · 160 阅读 · 0 评论 -
PL/SQL 循环 FOR
Declare counter Binary_Integer :=40; Begin For counter In 30..40 Loop Insert Into test Values('ddd',counter); End Loop;End;2006-12-20 22:29:34 · 275 阅读 · 0 评论 -
java 通过调用存储过程获取结果集
一般在java中,数据查询是通过Statement, PreparedStatement获取结果集,今天向大家介绍通过CallableStatement调用存储过程,从而获取结果集. 本文是所用的数据库为oracle. 一. 测试数据库表: sql 代码 create table wilent_user( ...2006-12-25 21:47:25 · 340 阅读 · 0 评论 -
通过oracle实现 : select * from 存储教程(或函数) 例子
在上个例子中,我们演示了通过java调用存储过程,获取数据集.可能有人觉得这个调用有点麻烦,本文又演示多个例子. 示范: "select * from table(wilent_group_count1)"; 其中wilent_group_count1为oracle函数,返回一个用户所需的虚拟表,再通过table()函数转换成表. ...2006-12-27 21:48:00 · 891 阅读 · 0 评论 -
PL/SQL入门系列--集合之:index-by表
与很多语言一样,oracle也有其集合结构,首先向大家介绍 :index-by表 index-by 类似c,c++,java中的数组. 一. 定义语法为: TYPE TableType IS TABLE OF type INDEX BY BINARY_INTEER; 二. 示例 1. ...2006-12-28 20:50:44 · 488 阅读 · 0 评论 -
PL/SQL入门系列--集合之:嵌套表
本文继续向你介绍集合中的嵌套表, 嵌套表类似平时所见的数据库表,嵌套表可以储存在数据库中. 一. 定义语法为: TYPE table_name is TABLE OF table_type [NOT NULL]; 二.示例 sql 代码 --自...2006-12-28 21:13:23 · 144 阅读 · 0 评论 -
PL/SQL入门系列--集合之:可变数组
本文向你介绍集合的:可变数组. 可变数组的访问与嵌套表,index-by表访问类似. 一. 定义语法 TYPE type_name IS {VARRAY | VARYING ARRAY} (maximum_size) OF element_type[NOT NULL]; 二.示例 ...2006-12-28 21:48:47 · 130 阅读 · 0 评论