MySQL开发者SQL权威指南-附录(8)

时间:2025-07-07

MySQL开发者SQL权威指南的附录文档

Create Table语句

<create table statement> ::=

CREATE [ TEMPORARY ] TABLE [ IF NOT EXISTS ]

<table specification><table structure>

[ <table option>... ]

Create Trigger语句

<create trigger statement> ::=

CREATE[ <definer option> ]

TRIGGER <trigger name><trigger moment><trigger event><trigger action><trigger moment> ::= BEFORE | AFTER<trigger event> ::=

{ INSERT | DELETE | UPDATE }

ON <table specification>FOR EACH ROW<trigger action> ::= <sql statement>

Create User语句

<create user statement> ::=

CREATE USER<user specification>

[ , <user specification> ]...

<user specification> ::=

<user name> [ IDENTIFIED BY [ PASSWORD ]<password> ]

Create View语句

<create view statement> ::=

CREATE [ OR REPLACE ]

[ <definer option> ]

[ <sql security option> ]

[ ALGORITHM = { MERGE | TEMPTABLE UNDEFINED } ]

VIEW <view name> [ <column list> ] AS<table expression>[ WITH [ CASCADED | LOCAL ] CHECK OPTION ]

Deallocate Prepare语句

<deallocate prepare statement> ::=

{ DEALLOCATE | DROP } PREPARE <statement name>

Declare Condition语句

<declare condition statement> ::=

MySQL开发者SQL权威指南的附录文档

608附录

DECLARE <condition name> CONDITION FOR

{ SQLSTATE [ VALUE ] <sqlstate value> } |<mysql error code>

Declare Cursor语句

<declare cursor statement> ::=

DECLARE<cursor name> CURSOR FOR <table expression>

Declare Handler语句

<declare handler statement> ::=

DECLARE <handler type> HANDLER FOR <condition value list>

<procedural statement><handler type> ::=

CONTINUE |EXIT |UNDO

<condition value list> ::=

<condition value> [ , <condition value> ]...<condition value> ::=

SQLSTATE [ VALUE ] <sqlstate value> |<mysql error code> |SQLWARNING |NOT FOUND |SQLEXCEPTION |<condition name>

Declare Variable语句

<declare variable statement> ::=

DECLARE <variable list> <data type>

[ DEFAULT <scalar expression> ]

Delete语句

为了避免不必要的重复定义,这里给出DELETE语句的两个定义。第一个定义从一个表中删除行;第二个定义同时从多个表中删除行。

<delete statement> ::=

DELETE [ IGNORE ]

FROM <table reference>[ <where clause> ][ <order by clause> ][ <limit clause> ]

<delete statement> ::=

{ DELETE [ LOW_PRIORITY ] [ IGNORE ]

<table reference> [ , <table reference> ]...

FROM <table reference> [ , <table reference >]...

…… 此处隐藏:11字,全部文档内容请下载后查看。喜欢就下载吧 ……
MySQL开发者SQL权威指南-附录(8).doc 将本文的Word文档下载到电脑

精彩图片

热门精选

大家正在看

× 游客快捷下载通道(下载后可以自由复制和排版)

限时特价:7 元/份 原价:20元

支付方式:

开通VIP包月会员 特价:29元/月

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信:fanwen365 QQ:370150219