Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Greenplum
Gpdb
提交
7d3ab8ac
G
Gpdb
项目概览
Greenplum
/
Gpdb
通知
7
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
Gpdb
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
7d3ab8ac
编写于
10月 23, 2005
作者:
T
Tom Lane
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
A bit of minor copy-editing.
上级
55337e40
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
18 addition
and
8 deletion
+18
-8
doc/src/sgml/ddl.sgml
doc/src/sgml/ddl.sgml
+4
-4
doc/src/sgml/syntax.sgml
doc/src/sgml/syntax.sgml
+14
-4
未找到文件。
doc/src/sgml/ddl.sgml
浏览文件 @
7d3ab8ac
<!-- $PostgreSQL: pgsql/doc/src/sgml/ddl.sgml,v 1.4
4 2005/08/13 01:55:41 momjian
Exp $ -->
<!-- $PostgreSQL: pgsql/doc/src/sgml/ddl.sgml,v 1.4
5 2005/10/23 19:29:49 tgl
Exp $ -->
<chapter id="ddl">
<title>Data Definition</title>
...
...
@@ -240,7 +240,7 @@ CREATE TABLE products (
in a table. For many applications, however, the constraint they
provide is too coarse. For example, a column containing a product
price should probably only accept positive values. But there is no
data type that accepts only positive numbers. Another issue is
standard
data type that accepts only positive numbers. Another issue is
that you might want to constrain column data with respect to other
columns or rows. For example, in a table containing product
information, there should only be one row for each product number.
...
...
@@ -431,7 +431,7 @@ CREATE TABLE products (
IS NOT NULL)</literal>, but in
<productname>PostgreSQL</productname> creating an explicit
not-null constraint is more efficient. The drawback is that you
cannot give explicit names to not-null constraints created th
at
cannot give explicit names to not-null constraints created th
is
way.
</para>
...
...
@@ -551,7 +551,7 @@ CREATE TABLE products (
columns included in the constraint are equal.
However, null values are not considered equal in this
comparison. That means even in the presence of a
unique constraint it is possible to store
an unlimited number of
unique constraint it is possible to store
duplicate
rows that contain a null value in at least one of the constrained
columns. This behavior conforms to the SQL standard, but we have
heard that other SQL databases may not follow this rule. So be
...
...
doc/src/sgml/syntax.sgml
浏览文件 @
7d3ab8ac
<!--
$PostgreSQL: pgsql/doc/src/sgml/syntax.sgml,v 1.10
3 2005/08/14 22:19:50 petere
Exp $
$PostgreSQL: pgsql/doc/src/sgml/syntax.sgml,v 1.10
4 2005/10/23 19:29:49 tgl
Exp $
-->
<chapter id="sql-syntax">
...
...
@@ -260,7 +260,7 @@ UPDATE "my_table" SET "a" = 5;
<literal>\n</literal> is a newline, <literal>\r</literal> is a
carriage return, <literal>\t</literal> is a tab. Also supported is
<literal>\<replaceable>digits</replaceable></literal>, where
<replaceable>d
dd
</replaceable> represents an octal byte value, and
<replaceable>d
igits
</replaceable> represents an octal byte value, and
<literal>\x<replaceable>hexdigits</replaceable></literal>, where
<replaceable>hexdigits</replaceable> represents a hexadecimal byte value.
(It is your responsibility that the byte sequences you create are
...
...
@@ -544,6 +544,16 @@ CAST ( '<replaceable>string</replaceable>' AS <replaceable>type</replaceable> )
is that it does not work for array types; use <literal>::</literal>
or <literal>CAST()</literal> to specify the type of an array constant.
</para>
<para>
The <literal>CAST()</> syntax conforms to SQL. The
<literal><replaceable>type</replaceable> '<replaceable>string</replaceable>'</literal>
syntax is a generalization of the standard: SQL specifies this syntax only
for a few datatypes, but <productname>PostgreSQL</productname> allows it
for all types. The syntax with
<literal>::</literal> is historical <productname>PostgreSQL</productname>
usage, as is the function-call syntax.
</para>
</sect3>
</sect2>
...
...
@@ -1105,8 +1115,8 @@ CREATE FUNCTION dept(text) RETURNS dept
LANGUAGE SQL;
</programlisting>
Here the <literal>$1</literal>
will be replaced by
the first
function argument when the function is invoked.
Here the <literal>$1</literal>
references the value of
the first
function argument when
ever
the function is invoked.
</para>
</sect2>
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录