[英]编程快参 oracle plsql cheatsheet

更新时间:2023-05-16 04:13:56 阅读: 评论:0

Oracle PL/SQL
Cheatsheet
春节福字
Symbols
; Semicolon.Statement terminator
生日礼物送男生% Percent sign Attribute indicator (cursor attributes like
%ISOPEN and indirect declaration attributes like %ROWTYPE). Also ud as multibyte wildcard symbol, as in SQL.
_ Single underscore Single-byte wildcard symbol, as in SQL
: Colon Host variable indicator, such as :block.item in Oracle Forms
** Double asterisk Exponentiation operator团日活动策划案
< > and !=Not equals"
|| Double vertical bar Concatenation operator
<< and >>Label delimiters
:=Assignment operator
=>Association operator for positional notation
--Double dash: single-line comment indicator
/* and */Beginning and ending multiline comment block delimiters
Data Types.
Databa types NUMBER
CHAR(N), VARCHAR2(N)
DATE
LONG LONG RAW
朱雀ROWID MLSLABEL Definition
Ud to store any number
Ud for storing text
Oracle system date
Stores large blocks of text Stores large blocks of binary data Smaller binary data store
Uesd for row identifier
加密软件哪个最好用Security label
Non databa types.DEC, DECIMAL, REAL, DOUBLE-PRECISION, INTEGER, INT, SMALLINT, NATURAL, POSITIVE, NUMERIC, BINARY-INTEGER, CHARACTER, VARCHAR, BOOLEAN, TABLE, RECORD
PLSQL Module types
Procedure A non-formal function that can accept paremeters via value or reference. Similar in form to a function.
燕塞湖Function A classical function that returns one value. Usually contains declaration, execution and exception ctions.
Package A library, consisting of a specification with function/prototype signatures, and a body with actual code. eg
Trigger
Code attached to a table that fires on certian conditions.
Module Sections or Blocks
Variable Declaration DECLARE
pid%TYPE, pi CONSTANT number := 3.14, ratio REAL,.. BEGIN..
Executable Section .. BEGIN lect * into my_employee id = 42; END; ..
Exception Handler.END; EXCEPTIONS .. END;
Package Syntax
Specification PACKAGE package_name
IS
[ declarations of variables and types ] [ specifications of cursors ]
[ specifications of modules ]
END [ package_name ];
Body PACKAGE BODY package_name
IS
[ declarations of variables and types ] [ specification and SELECT statement of cursors ]
[ specification and body of modules ] [ BEGIN
怀孕可以吃兔肉吗>读书伴我成长作文400字
executable statements ]
[ EXCEPTION
exception handlers ]
END [ package_name ];
Filename Extensions
General SQL*Plus
script
.sql
Testing script.tst
Stored procedure.sp
Stored function.sf
Stored package body spb
Stored package
specification
.sps
Implict cursor attributes.
%NOTFOUND True if fetch did not return row.
%ROWCOUNT Number of rows procesd by this cursor %FOUND Opposite of %NOTFOUND
%ISOPEN If currently open for processing then true.
Transaction processing
Same Options as SQL COMMIT, ROLLBACK, SAVEPOINT Transaction begins at
execution of first
change of data.
Rollbacks go to last COMMIT or SAVE_POINT
DBMS_TRANSACTION A package with functions for transaction control.

本文发布于:2023-05-16 04:13:56,感谢您对本站的认可!

本文链接:https://www.wtabcd.cn/fanwen/fan/89/902160.html

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。

标签:读书   兔肉   策划案   软件   活动
相关文章
留言与评论(共有 0 条评论)
   
验证码:
推荐文章
排行榜
Copyright ©2019-2022 Comsenz Inc.Powered by © 专利检索| 网站地图