Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitcda6a8d

Browse files
committed
Remove deprecated abstime, reltime, tinterval datatypes.
These types have been deprecated for a *long* time.Catversion bump, for obvious reasons.Author: Andres FreundDiscussion:https://postgr.es/m/20181009192237.34wjp3nmw7oynmmr@alap3.anarazel.dehttps://postgr.es/m/20171213080506.cwjkpcz3bkk6yz2u@alap3.anarazel.dehttps://postgr.es/m/25615.1513115237@sss.pgh.pa.us
1 parent2d10def commitcda6a8d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+29
-3318
lines changed

‎doc/src/sgml/brin.sgml

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -129,17 +129,6 @@ LOG: request for BRIN range summarization for index "brin_wi_idx" page 128 was
129129
</row>
130130
</thead>
131131
<tbody>
132-
<row>
133-
<entry><literal>abstime_minmax_ops</literal></entry>
134-
<entry><type>abstime</type></entry>
135-
<entry>
136-
<literal>&lt;</literal>
137-
<literal>&lt;=</literal>
138-
<literal>=</literal>
139-
<literal>&gt;=</literal>
140-
<literal>&gt;</literal>
141-
</entry>
142-
</row>
143132
<row>
144133
<entry><literal>int8_minmax_ops</literal></entry>
145134
<entry><type>bigint</type></entry>
@@ -388,17 +377,6 @@ LOG: request for BRIN range summarization for index "brin_wi_idx" page 128 was
388377
<literal>&gt;</literal>
389378
</entry>
390379
</row>
391-
<row>
392-
<entry><literal>reltime_minmax_ops</literal></entry>
393-
<entry><type>reltime</type></entry>
394-
<entry>
395-
<literal>&lt;</literal>
396-
<literal>&lt;=</literal>
397-
<literal>=</literal>
398-
<literal>&gt;=</literal>
399-
<literal>&gt;</literal>
400-
</entry>
401-
</row>
402380
<row>
403381
<entry><literal>int2_minmax_ops</literal></entry>
404382
<entry><type>smallint</type></entry>

‎doc/src/sgml/catalogs.sgml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10646,7 +10646,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1064610646

1064710647
<row>
1064810648
<entry><structfield>valuntil</structfield></entry>
10649-
<entry><type>abstime</type></entry>
10649+
<entry><type>timestamptz</type></entry>
1065010650
<entry></entry>
1065110651
<entry>Password expiry time (only used for password authentication)</entry>
1065210652
</row>
@@ -11125,7 +11125,7 @@ SELECT * FROM pg_locks pl LEFT JOIN pg_prepared_xacts ppx
1112511125

1112611126
<row>
1112711127
<entry><structfield>valuntil</structfield></entry>
11128-
<entry><type>abstime</type></entry>
11128+
<entry><type>timestamptz</type></entry>
1112911129
<entry>Password expiry time (only used for password authentication)</entry>
1113011130
</row>
1113111131

‎doc/src/sgml/datatype.sgml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1711,14 +1711,6 @@ MINUTE TO SECOND
17111711
any application.
17121712
</para>
17131713

1714-
<para>
1715-
The types <type>abstime</type>
1716-
and <type>reltime</type> are lower precision types which are used internally.
1717-
You are discouraged from using these types in
1718-
applications; these internal types
1719-
might disappear in a future release.
1720-
</para>
1721-
17221714
<sect2 id="datatype-datetime-input">
17231715
<title>Date/Time Input</title>
17241716

‎doc/src/sgml/xfunc.sgml

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -2069,16 +2069,6 @@ memcpy(destination->data, buffer, 40);
20692069
</row>
20702070
</thead>
20712071
<tbody>
2072-
<row>
2073-
<entry><type>abstime</type></entry>
2074-
<entry><type>AbsoluteTime</type></entry>
2075-
<entry><filename>utils/nabstime.h</filename></entry>
2076-
</row>
2077-
<row>
2078-
<entry><type>bigint</type> (<type>int8</type>)</entry>
2079-
<entry><type>int64</type></entry>
2080-
<entry><filename>postgres.h</filename></entry>
2081-
</row>
20822072
<row>
20832073
<entry><type>boolean</type></entry>
20842074
<entry><type>bool</type></entry>
@@ -2179,11 +2169,6 @@ memcpy(destination->data, buffer, 40);
21792169
<entry><type>regproc</type></entry>
21802170
<entry><filename>postgres.h</filename></entry>
21812171
</row>
2182-
<row>
2183-
<entry><type>reltime</type></entry>
2184-
<entry><type>RelativeTime</type></entry>
2185-
<entry><filename>utils/nabstime.h</filename></entry>
2186-
</row>
21872172
<row>
21882173
<entry><type>text</type></entry>
21892174
<entry><type>text*</type></entry>
@@ -2209,11 +2194,6 @@ memcpy(destination->data, buffer, 40);
22092194
<entry><type>Timestamp*</type></entry>
22102195
<entry><filename>datatype/timestamp.h</filename></entry>
22112196
</row>
2212-
<row>
2213-
<entry><type>tinterval</type></entry>
2214-
<entry><type>TimeInterval</type></entry>
2215-
<entry><filename>utils/nabstime.h</filename></entry>
2216-
</row>
22172197
<row>
22182198
<entry><type>varchar</type></entry>
22192199
<entry><type>VarChar*</type></entry>

‎src/backend/access/hash/hashvalidate.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -311,7 +311,6 @@ check_hash_func_signature(Oid funcid, int16 amprocnum, Oid argtype)
311311
*/
312312
if ((funcid==F_HASHINT4||funcid==F_HASHINT4EXTENDED)&&
313313
(argtype==DATEOID||
314-
argtype==ABSTIMEOID||argtype==RELTIMEOID||
315314
argtype==XIDOID||argtype==CIDOID))
316315
/* okay, allowed use of hashint4() */ ;
317316
elseif ((funcid==F_TIMESTAMP_HASH||

‎src/backend/catalog/system_views.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ CREATE VIEW pg_shadow AS
4141
rolreplicationAS userepl,
4242
rolbypassrlsAS usebypassrls,
4343
rolpasswordAS passwd,
44-
rolvaliduntil::abstimeAS valuntil,
44+
rolvaliduntilAS valuntil,
4545
setconfigAS useconfig
4646
FROM pg_authidLEFT JOIN pg_db_role_setting s
4747
ON (pg_authid.oid= setroleAND setdatabase=0)

‎src/backend/utils/adt/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ OBJS = acl.o amutils.o arrayfuncs.o array_expanded.o array_selfuncs.o \
1717
float.o format_type.o formatting.o genfile.o\
1818
geo_ops.o geo_selfuncs.o geo_spgist.o inet_cidr_ntop.o inet_net_pton.o\
1919
int.o int8.o json.o jsonb.o jsonb_gin.o jsonb_op.o jsonb_util.o\
20-
jsonfuncs.o like.o lockfuncs.o mac.o mac8.o misc.onabstime.oname.o\
20+
jsonfuncs.o like.o lockfuncs.o mac.o mac8.o misc.o name.o\
2121
network.o network_gist.o network_selfuncs.o network_spgist.o\
2222
numeric.o numutils.o oid.o oracle_compat.o\
2323
orderedsetaggs.o pg_locale.o pg_lsn.o pg_upgrade_support.o\

‎src/backend/utils/adt/date.c

Lines changed: 0 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
#include"utils/builtins.h"
3030
#include"utils/date.h"
3131
#include"utils/datetime.h"
32-
#include"utils/nabstime.h"
3332
#include"utils/sortsupport.h"
3433

3534
/*
@@ -1170,55 +1169,6 @@ timestamptz_date(PG_FUNCTION_ARGS)
11701169
}
11711170

11721171

1173-
/* abstime_date()
1174-
* Convert abstime to date data type.
1175-
*/
1176-
Datum
1177-
abstime_date(PG_FUNCTION_ARGS)
1178-
{
1179-
AbsoluteTimeabstime=PG_GETARG_ABSOLUTETIME(0);
1180-
DateADTresult;
1181-
structpg_tmtt,
1182-
*tm=&tt;
1183-
inttz;
1184-
1185-
switch (abstime)
1186-
{
1187-
caseINVALID_ABSTIME:
1188-
ereport(ERROR,
1189-
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
1190-
errmsg("cannot convert reserved abstime value to date")));
1191-
result=0;/* keep compiler quiet */
1192-
break;
1193-
1194-
caseNOSTART_ABSTIME:
1195-
DATE_NOBEGIN(result);
1196-
break;
1197-
1198-
caseNOEND_ABSTIME:
1199-
DATE_NOEND(result);
1200-
break;
1201-
1202-
default:
1203-
abstime2tm(abstime,&tz,tm,NULL);
1204-
/* Prevent overflow in Julian-day routines */
1205-
if (!IS_VALID_JULIAN(tm->tm_year,tm->tm_mon,tm->tm_mday))
1206-
ereport(ERROR,
1207-
(errcode(ERRCODE_DATETIME_VALUE_OUT_OF_RANGE),
1208-
errmsg("abstime out of range for date")));
1209-
result=date2j(tm->tm_year,tm->tm_mon,tm->tm_mday)-POSTGRES_EPOCH_JDATE;
1210-
/* Now check for just-out-of-range dates */
1211-
if (!IS_VALID_DATE(result))
1212-
ereport(ERROR,
1213-
(errcode(ERRCODE_DATETIME_VALUE_OUT_OF_RANGE),
1214-
errmsg("abstime out of range for date")));
1215-
break;
1216-
}
1217-
1218-
PG_RETURN_DATEADT(result);
1219-
}
1220-
1221-
12221172
/*****************************************************************************
12231173
* Time ADT
12241174
*****************************************************************************/

‎src/backend/utils/adt/formatting.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@
4949
*- better number building (formatting) / parsing, now it isn't
5050
* ideal code
5151
*- use Assert()
52-
*- add support for abstime
5352
*- add support for roman number to standard number conversion
5453
*- add support for number spelling
5554
*- add support for string to string formatting (we must be better

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp