EXECUTE 中文man页面

系统
EXECUTE 用于执行一个前面准备好的语句。 因为一个准备好的查询只在会话的生命期里存在,那么准备好的查询必须是在当前会话的前些时候用 PREPARE 语句执行的。

NAME

EXECUTE - 执行一个准备好的查询

SYNOPSIS

EXECUTE plan_name [ (parameter [, ...] ) ]

DESCRIPTION 描述

EXECUTE 用于执行一个前面准备好的语句。 因为一个准备好的查询只在会话的生命期里存在,那么准备好的查询必须是在当前会话的前些时候用 PREPARE 语句执行的。


 如果创建语句的 PREPARE 语句声明了一些参数, 那么传递给 EXECUTE 语句的必须是一个兼容的参数集, 否则就会生成一个错误。请注意(和函数不同),准备好的语句不会基于参数的类型或者个数重载: 在一次数据库会话过程中,准备好的语句的名字必须是***的。


 有关创建和使用准备好的语句的更多信息, 请参阅 PREPARE [prepare(7)].  

PARAMETERS 参数

plan_name

 要执行的准备好的语句。
parameter

 给准备好的语句的一个参数的具体数值。 它必须是一个生成与创建这个准备好的语句的 PREPARE 语句指定参数位置的参数相兼容的数据类型的表达式。

COMPATIBILITY 兼容性


 SQL 标准包括一个 EXECUTE 语句, 但它只是用于嵌入的 SQL 客户端。PostgreSQL  实现的 EXECUTE 的语法也略微不同。  

#p#

NAME

EXECUTE - execute a prepared statement

SYNOPSIS

EXECUTE plan_name [ (parameter [, ...] ) ]

DESCRIPTION

EXECUTE is used to execute a previously prepared statement. Since prepared statements only exist for the duration of a session, the prepared statement must have been created by a PREPARE statement executed earlier in the current session.

If the PREPARE statement that created the statement specified some parameters, a compatible set of parameters must be passed to the EXECUTE statement, or else an error is raised. Note that (unlike functions) prepared statements are not overloaded based on the type or number of their parameters; the name of a prepared statement must be unique within a database session.

For more information on the creation and usage of prepared statements, see PREPARE [prepare(7)].  

PARAMETERS

plan_name
The name of the prepared statement to execute.
parameter
The actual value of a parameter to the prepared statement. This must be an expression yielding a value of a type compatible with the data type specified for this parameter position in the PREPARE command that created the prepared statement.

COMPATIBILITY

The SQL standard includes an EXECUTE statement, but it is only for use in embedded SQL. This version of the EXECUTE statement also uses a somewhat different syntax.

责任编辑:韩亚珊 来源: CMPP.net
相关推荐

2011-08-24 16:48:36

man中文man

2011-08-15 10:21:09

man中文man

2011-08-11 16:11:49

at中文man

2011-08-25 10:21:56

man.conf中文man

2011-08-12 14:58:05

killall中文man

2011-07-15 16:58:36

ac中文man

2011-08-15 11:10:48

more中文man

2011-08-25 17:03:51

pclose中文man

2011-08-15 14:10:37

tar中文man

2011-08-16 10:42:30

rmmod中文man

2011-08-23 17:49:36

zdump中文man

2011-08-15 15:10:49

wall中文man

2011-08-23 15:06:03

quotastats中文man

2011-08-15 17:35:50

ar中文man

2011-08-25 09:07:16

suffixes中文man

2011-08-18 15:21:37

autofs中文man

2011-08-25 15:19:39

dirname中文man

2011-08-25 17:34:50

setlinebuf中文man

2011-08-15 15:17:14

ac中文man

2011-08-16 10:14:51

sndconfig中文man
点赞
收藏

51CTO技术栈公众号