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
5c35b597
Commit
5c35b597
authored
Oct 03, 2001
by
Tom Lane
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Teach format_type about time/timestamp precision, so that pg_dump and
psql's \d option work properly.
parent
2684f15e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
4 deletions
+24
-4
src/backend/utils/adt/format_type.c
src/backend/utils/adt/format_type.c
+24
-4
No files found.
src/backend/utils/adt/format_type.c
View file @
5c35b597
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
* Portions Copyright (c) 1994, Regents of the University of California
* Portions Copyright (c) 1994, Regents of the University of California
*
*
* IDENTIFICATION
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/format_type.c,v 1.1
6 2001/09/28 08:09:10 thomas
Exp $
* $Header: /cvsroot/pgsql/src/backend/utils/adt/format_type.c,v 1.1
7 2001/10/03 18:32:42 tgl
Exp $
*
*
*-------------------------------------------------------------------------
*-------------------------------------------------------------------------
*/
*/
...
@@ -200,16 +200,36 @@ format_type_internal(Oid type_oid, int32 typemod, bool allow_invalid)
...
@@ -200,16 +200,36 @@ format_type_internal(Oid type_oid, int32 typemod, bool allow_invalid)
buf
=
pstrdup
(
"numeric"
);
buf
=
pstrdup
(
"numeric"
);
break
;
break
;
case
TIMEOID
:
if
(
with_typemod
&&
typemod
>
0
)
buf
=
psnprintf
(
50
,
"time(%d) without time zone"
,
typemod
);
else
buf
=
pstrdup
(
"time without time zone"
);
break
;
case
TIMETZOID
:
case
TIMETZOID
:
buf
=
pstrdup
(
"time with time zone"
);
if
(
with_typemod
&&
typemod
>
0
)
buf
=
psnprintf
(
50
,
"time(%d) with time zone"
,
typemod
);
else
buf
=
pstrdup
(
"time with time zone"
);
break
;
break
;
case
TIMESTAMPOID
:
case
TIMESTAMPOID
:
buf
=
pstrdup
(
"timestamp without time zone"
);
if
(
with_typemod
&&
typemod
>
0
)
buf
=
psnprintf
(
50
,
"timestamp(%d) without time zone"
,
typemod
);
else
buf
=
pstrdup
(
"timestamp without time zone"
);
break
;
break
;
case
TIMESTAMPTZOID
:
case
TIMESTAMPTZOID
:
buf
=
pstrdup
(
"timestamp with time zone"
);
if
(
with_typemod
&&
typemod
>
0
)
buf
=
psnprintf
(
50
,
"timestamp(%d) with time zone"
,
typemod
);
else
buf
=
pstrdup
(
"timestamp with time zone"
);
break
;
break
;
case
VARBITOID
:
case
VARBITOID
:
...
...
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