Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
f89c972a
Commit
f89c972a
authored
May 18, 2003
by
Peter Eisentraut
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add documentation for information schema, and some corrections on some
views.
parent
6d7ff848
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
1776 additions
and
17 deletions
+1776
-17
doc/src/sgml/filelist.sgml
doc/src/sgml/filelist.sgml
+2
-1
doc/src/sgml/information_schema.sgml
doc/src/sgml/information_schema.sgml
+1735
-0
doc/src/sgml/postgres.sgml
doc/src/sgml/postgres.sgml
+2
-1
src/backend/catalog/information_schema.sql
src/backend/catalog/information_schema.sql
+37
-15
No files found.
doc/src/sgml/filelist.sgml
View file @
f89c972a
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/filelist.sgml,v 1.2
8 2003/04/10 01:22:44
petere Exp $ -->
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/filelist.sgml,v 1.2
9 2003/05/18 20:55:56
petere Exp $ -->
<!entity history SYSTEM "history.sgml">
<!entity info SYSTEM "info.sgml">
...
...
@@ -63,6 +63,7 @@
<!entity func-ref SYSTEM "func-ref.sgml">
<!entity gist SYSTEM "gist.sgml">
<!entity indexcost SYSTEM "indexcost.sgml">
<!entity infoschema SYSTEM "information_schema.sgml">
<!entity jdbc SYSTEM "jdbc.sgml">
<!entity libpgeasy SYSTEM "libpgeasy.sgml">
<!entity libpq SYSTEM "libpq.sgml">
...
...
doc/src/sgml/information_schema.sgml
0 → 100644
View file @
f89c972a
This diff is collapsed.
Click to expand it.
doc/src/sgml/postgres.sgml
View file @
f89c972a
<!--
$Header: /cvsroot/pgsql/doc/src/sgml/postgres.sgml,v 1.5
1 2003/04/13 09:57:35
petere Exp $
$Header: /cvsroot/pgsql/doc/src/sgml/postgres.sgml,v 1.5
2 2003/05/18 20:55:56
petere Exp $
-->
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook V3.1//EN" [
...
...
@@ -189,6 +189,7 @@ $Header: /cvsroot/pgsql/doc/src/sgml/postgres.sgml,v 1.51 2003/04/13 09:57:35 pe
&ecpg;
&jdbc;
&pygresql;
&infoschema;
</part>
...
...
src/backend/catalog/information_schema.sql
View file @
f89c972a
...
...
@@ -4,7 +4,7 @@
*
* Copyright 2002, PostgreSQL Global Development Group
*
* $Id: information_schema.sql,v 1.
4 2003/03/20 05:06:55 momjian
Exp $
* $Id: information_schema.sql,v 1.
5 2003/05/18 20:55:57 petere
Exp $
*/
...
...
@@ -169,17 +169,28 @@ CREATE VIEW columns AS
AS
character_octet_length
,
CAST
(
CASE
WHEN
a
.
atttypid
IN
(
1700
)
THEN
((
a
.
atttypmod
-
4
)
>>
16
)
&
65535
ELSE
null
END
CASE
a
.
atttypid
WHEN
21
/*int2*/
THEN
16
WHEN
23
/*int4*/
THEN
32
WHEN
20
/*int8*/
THEN
64
WHEN
1700
/*numeric*/
THEN
((
a
.
atttypmod
-
4
)
>>
16
)
&
65535
WHEN
700
/*float4*/
THEN
24
/*FLT_MANT_DIG*/
WHEN
701
/*float8*/
THEN
53
/*DBL_MANT_DIG*/
ELSE
null
END
AS
cardinal_number
)
AS
numeric_precision
,
CAST
(
CASE
WHEN
a
.
atttypid
IN
(
1700
)
THEN
10
ELSE
null
END
CASE
WHEN
a
.
atttypid
IN
(
21
,
23
,
20
,
700
,
701
)
THEN
2
WHEN
a
.
atttypid
IN
(
1700
)
THEN
10
ELSE
null
END
AS
cardinal_number
)
AS
numeric_precision_radix
,
CAST
(
CASE
WHEN
a
.
atttypid
IN
(
1700
)
THEN
(
a
.
atttypmod
-
4
)
&
65535
ELSE
null
END
CASE
WHEN
a
.
atttypid
IN
(
21
,
23
,
20
)
THEN
0
WHEN
a
.
atttypid
IN
(
1700
)
THEN
(
a
.
atttypmod
-
4
)
&
65535
ELSE
null
END
AS
cardinal_number
)
AS
numeric_scale
,
...
...
@@ -203,18 +214,18 @@ CREATE VIEW columns AS
CAST
(
null
AS
sql_identifier
)
AS
collation_schema
,
CAST
(
null
AS
sql_identifier
)
AS
collation_name
,
CAST
(
CASE
WHEN
t
.
typ
basetype
<>
0
THEN
current_database
()
ELSE
null
END
CAST
(
CASE
WHEN
t
.
typ
type
=
'd'
THEN
current_database
()
ELSE
null
END
AS
sql_identifier
)
AS
domain_catalog
,
CAST
(
CASE
WHEN
t
.
typ
basetype
<>
0
THEN
nt
.
nspname
ELSE
null
END
CAST
(
CASE
WHEN
t
.
typ
type
=
'd'
THEN
nt
.
nspname
ELSE
null
END
AS
sql_identifier
)
AS
domain_schema
,
CAST
(
CASE
WHEN
t
.
typ
basetype
<>
0
THEN
t
.
typname
ELSE
null
END
CAST
(
CASE
WHEN
t
.
typ
type
=
'd'
THEN
t
.
typname
ELSE
null
END
AS
sql_identifier
)
AS
domain_name
,
CAST
(
CASE
WHEN
t
.
typ
basetype
=
0
THEN
current_database
()
ELSE
null
END
CAST
(
CASE
WHEN
t
.
typ
type
<>
'd'
THEN
current_database
()
ELSE
null
END
AS
sql_identifier
)
AS
udt_catalog
,
CAST
(
CASE
WHEN
t
.
typ
basetype
=
0
THEN
nt
.
nspname
ELSE
null
END
CAST
(
CASE
WHEN
t
.
typ
type
<>
'd'
THEN
nt
.
nspname
ELSE
null
END
AS
sql_identifier
)
AS
udt_schema
,
CAST
(
CASE
WHEN
t
.
typ
basetype
=
0
THEN
t
.
typname
ELSE
null
END
CAST
(
CASE
WHEN
t
.
typ
type
<>
'd'
THEN
t
.
typname
ELSE
null
END
AS
sql_identifier
)
AS
udt_name
,
CAST
(
null
AS
sql_identifier
)
AS
scope_catalog
,
...
...
@@ -298,17 +309,28 @@ CREATE VIEW domains AS
CAST
(
null
AS
sql_identifier
)
AS
collation_name
,
CAST
(
CASE
WHEN
t
.
typbasetype
IN
(
1700
)
THEN
((
t
.
typtypmod
-
4
)
>>
16
)
&
65535
ELSE
null
END
CASE
t
.
typbasetype
WHEN
21
/*int2*/
THEN
16
WHEN
23
/*int4*/
THEN
32
WHEN
20
/*int8*/
THEN
64
WHEN
1700
/*numeric*/
THEN
((
t
.
typtypmod
-
4
)
>>
16
)
&
65535
WHEN
700
/*float4*/
THEN
24
/*FLT_MANT_DIG*/
WHEN
701
/*float8*/
THEN
53
/*DBL_MANT_DIG*/
ELSE
null
END
AS
cardinal_number
)
AS
numeric_precision
,
CAST
(
CASE
WHEN
t
.
typbasetype
IN
(
1700
)
THEN
10
ELSE
null
END
CASE
WHEN
t
.
typbasetype
IN
(
21
,
23
,
20
,
700
,
701
)
THEN
2
WHEN
t
.
typbasetype
IN
(
1700
)
THEN
10
ELSE
null
END
AS
cardinal_number
)
AS
numeric_precision_radix
,
CAST
(
CASE
WHEN
t
.
typbasetype
IN
(
1700
)
THEN
(
t
.
typtypmod
-
4
)
&
65535
ELSE
null
END
CASE
WHEN
t
.
typbasetype
IN
(
21
,
23
,
20
)
THEN
0
WHEN
t
.
typbasetype
IN
(
1700
)
THEN
(
t
.
typtypmod
-
4
)
&
65535
ELSE
null
END
AS
cardinal_number
)
AS
numeric_scale
,
...
...
@@ -347,11 +369,11 @@ CREATE VIEW domains AS
WHERE
rs
.
oid
=
t
.
typnamespace
AND
t
.
typtype
=
'd'
AND
t
.
typowner
=
u
.
usesysid
AND
(
u
.
usename
=
CURRENT_USER
AND
(
u
.
usename
=
current_user
OR
EXISTS
(
SELECT
1
FROM
pg_user
AS
u2
WHERE
rs
.
nspowner
=
u2
.
usesysid
AND
u2
.
usename
=
CURRENT_USER
)
AND
u2
.
usename
=
current_user
)
OR
EXISTS
(
SELECT
1
FROM
pg_user
AS
u3
,
pg_attribute
AS
a3
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment