PL/SQL个人学习笔记(二)
IF条件
declare
cursor s is
select version from city_server t;
s_ city_server.version%type;
begin
open s;
fetch s into s_;
if s_>2
then
DBMS_OUTPUT.put_line(s_);
end if;
close s;
end;
LOOP循环
declare
cursor s is
select version from city_server t;
s_ city_server.version%type;
begin
open s;
loop
fetch s into s_;
exit when s%notfound;
DBMS_OUTPUT.put_line(s_);
end loop;
close s;
end;
PL/SQL个人学习笔记(二)的更多相关文章
- postgreSQL PL/SQL编程学习笔记(二)
Control Structures of PL/SQL Control structures are probably the most useful (and important) part of ...
- postgreSQL PL/SQL编程学习笔记(六)——杂七杂八
1 PL/pgSQL Under the Hood This part discusses some implementation details that are frequently import ...
- postgreSQL PL/SQL编程学习笔记(三)——游标(Cursors)
Cursors Rather than executing a whole query at once, it is possible to set up a cursor that encapsul ...
- postgreSQL PL/SQL编程学习笔记(一)
1.Structure of PL/pgSQL The structure of PL/pgSQL is like below: [ <<label>> ] [ DECLARE ...
- postgreSQL PL/SQL编程学习笔记(五)——触发器(Triggers)
Trigger Procedures PL/pgSQL can be used to define trigger procedures on data changes or database eve ...
- postgreSQL PL/SQL编程学习笔记(四)
Errors and Messages 1. Reporting Errors and Messages Use the RAISE statement to report messages and ...
- PL/SQL个人学习笔记
资料1 -- Created on 2014/8/20 declare -- Local variables here i integer; begin i := 12; -- T ...
- 《SQL必知必会》学习笔记二)
<SQL必知必会>学习笔记(二) 咱们接着上一篇的内容继续.这一篇主要回顾子查询,联合查询,复制表这三类内容. 上一部分基本上都是简单的Select查询,即从单个数据库表中检索数据的单条语 ...
- Django学习笔记二
Django学习笔记二 模型类,字段,选项,查询,关联,聚合函数,管理器, 一 字段属性和选项 1.1 模型类属性命名限制 1)不能是python的保留关键字. 2)不允许使用连续的下划线,这是由dj ...
随机推荐
- 左右margin top问题百分比值
不想说今天心情有多差! 9点多開始发现一个"bug",需求是依据屏幕高度动态调整某个div的位置.代码大概是这种. <div style="margin-top: ...
- js调用跨域
web aapi 初体验 解决js调用跨域问题 跨域界定 常见跨域: 同IP不同端口: http:IP:8001/api/user http:IP:8002/api/user 不同IP不同 ...
- 一个ajax的Post要求
<1> $.post(url,[data],[callback],[type]) 第一个参数是地址,第二个参数是一个参数传递.第三个参数是一个回调函数.參数是请求返回数据的类型 //一个a ...
- Bubbles Shader in Houdini泡泡泡泡泡泡泡泡泡泡
watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQvY3Vja29u/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA==/d ...
- mysql位_01检查错误代码的方法
1 看到官方帮助文档 当前最新版本号的错误码见 http://dev.mysql.com/doc/refman/5.7/en/error-handling.html 2 在安装mysql的环境中调用m ...
- NSIS:检查某注册表键是否存在
原文NSIS:检查某注册表键是否存在 ;定义注册表主键!define HKEY_CLASSES_ROOT 0x80000000!define HKEY_CURRENT_USER ...
- 使用方便git命令检查记录的版本号
现在开始git大多数用户都经历过subversion,对于这两种开关的版本控制系统需要一段时间去适应.本文旨在帮助恢复一些,这些用户都熟悉的日志记录买家的习惯. 我们要熟悉一个详细的例子git中log ...
- MyEclipse中将项目导出jar包,以及转化成EXE文件
1.对于项目如何导出jar文件,和生成exe,解答目录如下: 首先生成jar文件,单击项目名称CF-users(这是我的协同过滤项目文件名称)右击--->Export如下图: 单击下一步 Sel ...
- 【电视桌面CSWUI】电视桌面(launcher)截图欣赏
网络播放器是最重要的电视桌面.cswui,我们公司做了一个非常大的人力,物力搞一个电视柜.后来一一介绍,简言之发送屏幕截图.给大家看. watermark/2/text/aHR0cDovL2Jsb2c ...
- ECLIPSE IDEA 调音 1
为自己所用IDE进行jvm优 首先进行日志输出配置 Eclipse 改动eclipse.ini IDEA 改动 idea.exe.vmoptions 添加打印日志的配置參数 -XX:+Print ...