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

Commit75133d9

Browse files
Jan WieckJan Wieck
Jan Wieck
authored and
Jan Wieck
committed
Reactivated LZTEXT data type and changed rule plan- and qual-strings
into lztext.Jan
1 parent97e38d3 commit75133d9

File tree

10 files changed

+95
-16
lines changed

10 files changed

+95
-16
lines changed

‎src/backend/utils/adt/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# Makefile for utils/adt
55
#
66
# IDENTIFICATION
7-
# $Header: /cvsroot/pgsql/src/backend/utils/adt/Makefile,v 1.34 2000/02/16 17:24:46 thomas Exp $
7+
# $Header: /cvsroot/pgsql/src/backend/utils/adt/Makefile,v 1.35 2000/02/27 12:02:32 wieck Exp $
88
#
99
#-------------------------------------------------------------------------
1010

@@ -25,7 +25,7 @@ endif
2525

2626
OBJS = acl.o arrayfuncs.o arrayutils.o bool.o cash.o char.o chunk.o\
2727
date.o datetime.o datum.o filename.o float.o\
28-
geo_ops.o geo_selfuncs.o int.o int8.o like.o\
28+
geo_ops.o geo_selfuncs.o int.o int8.o like.olztext.o\
2929
misc.o nabstime.o name.o not_in.o numeric.o numutils.o\
3030
oid.o oracle_compat.o\
3131
regexp.o regproc.o ruleutils.o selfuncs.o sets.o\

‎src/backend/utils/cache/relcache.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.90 2000/02/18 09:28:55 inoue Exp $
11+
* $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.91 2000/02/27 12:02:32 wieck Exp $
1212
*
1313
*-------------------------------------------------------------------------
1414
*/
@@ -36,6 +36,7 @@
3636

3737
#include"postgres.h"
3838

39+
#include"utils/builtins.h"
3940
#include"access/genam.h"
4041
#include"access/heapam.h"
4142
#include"access/istrat.h"
@@ -55,7 +56,6 @@
5556
#include"miscadmin.h"
5657
#include"storage/bufmgr.h"
5758
#include"storage/smgr.h"
58-
#include"utils/builtins.h"
5959
#include"utils/catcache.h"
6060
#include"utils/relcache.h"
6161
#include"utils/temprel.h"
@@ -688,15 +688,15 @@ RelationBuildRuleLock(Relation relation)
688688
Anum_pg_rewrite_ev_action,
689689
pg_rewrite_tupdesc,
690690
&isnull);
691-
ruleaction_str=textout((text*)DatumGetPointer(ruleaction));
691+
ruleaction_str=lztextout((lztext*)DatumGetPointer(ruleaction));
692692
rule->actions= (List*)stringToNode(ruleaction_str);
693693
pfree(ruleaction_str);
694694

695695
rule_evqual=heap_getattr(pg_rewrite_tuple,
696696
Anum_pg_rewrite_ev_qual,
697697
pg_rewrite_tupdesc,
698698
&isnull);
699-
rule_evqual_str=textout((text*)DatumGetPointer(rule_evqual));
699+
rule_evqual_str=lztextout((lztext*)DatumGetPointer(rule_evqual));
700700
rule->qual= (Node*)stringToNode(rule_evqual_str);
701701
pfree(rule_evqual_str);
702702

‎src/include/catalog/pg_amop.h

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
99
* Portions Copyright (c) 1994, Regents of the University of California
1010
*
11-
* $Id: pg_amop.h,v 1.30 2000/02/10 19:51:42 momjian Exp $
11+
* $Id: pg_amop.h,v 1.31 2000/02/27 12:02:33 wieck Exp $
1212
*
1313
* NOTES
1414
* the genbki.sh script reads this file and generates .bki
@@ -354,6 +354,17 @@ DATA(insert OID = 0 ( 403 1690 91 3 ));
354354
DATA(insertOID=0 (403169016954 ));
355355
DATA(insertOID=0 (4031690595 ));
356356

357+
/*
358+
* nbtree lztext
359+
*/
360+
361+
DATA(insertOID=0 (403166316591 ));
362+
DATA(insertOID=0 (403166316602 ));
363+
DATA(insertOID=0 (403166316573 ));
364+
DATA(insertOID=0 (403166316624 ));
365+
DATA(insertOID=0 (403166316615 ));
366+
367+
357368
/*
358369
*hash table _ops
359370
*/

‎src/include/catalog/pg_amproc.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
1111
* Portions Copyright (c) 1994, Regents of the University of California
1212
*
13-
* $Id: pg_amproc.h,v 1.20 2000/02/10 19:51:45 momjian Exp $
13+
* $Id: pg_amproc.h,v 1.21 2000/02/27 12:02:33 wieck Exp $
1414
*
1515
* NOTES
1616
* the genbki.sh script reads this file and generates .bki
@@ -100,6 +100,8 @@ DATA(insert OID = 0 (403 935 926 1));
100100
DATA(insertOID=0 (4036529261));
101101
DATA(insertOID=0 (403176817691));
102102
DATA(insertOID=0 (403169016931));
103+
DATA(insertOID=0 (403166316361));
104+
103105

104106

105107
/* hash */

‎src/include/catalog/pg_opclass.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
99
* Portions Copyright (c) 1994, Regents of the University of California
1010
*
11-
* $Id: pg_opclass.h,v 1.29 2000/02/16 17:26:07 thomas Exp $
11+
* $Id: pg_opclass.h,v 1.30 2000/02/27 12:02:33 wieck Exp $
1212
*
1313
* NOTES
1414
* the genbki.sh script reads this file and generates .bki
@@ -118,6 +118,8 @@ DATA(insert OID = 652 (cidr_ops 650 ));
118118
DESCR("");
119119
DATA(insertOID=1768 (numeric_ops1700 ));
120120
DESCR("");
121+
DATA(insertOID=1663 (lztext_ops1625 ));
122+
DESCR("");
121123
DATA(insertOID=1690 (bool_ops16 ));
122124
DESCR("");
123125

‎src/include/catalog/pg_operator.h

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
99
* Portions Copyright (c) 1994, Regents of the University of California
1010
*
11-
* $Id: pg_operator.h,v 1.70 2000/02/2402:05:28 tgl Exp $
11+
* $Id: pg_operator.h,v 1.71 2000/02/27 12:02:33 wieck Exp $
1212
*
1313
* NOTES
1414
* the genbki.sh script reads this file and generates .bki
@@ -684,6 +684,14 @@ DATA(insert OID = 1762 ( "%" PGUID 0 b t f 1700 1700 1700 00 0 0 numeric
684684
DATA(insertOID=1763 ("@"PGUID0ltf0170017000000numeric_abs-- ));
685685
DATA(insertOID=1788 ("-"PGUID0ltf0170017000000numeric_uminus-- ));
686686

687+
/* LZTEXT type */
688+
DATA(insertOID=1657 ("="PGUID0btf16251625161657165816591659lztext_eqeqseleqjoinsel ));
689+
DATA(insertOID=1658 ("<>"PGUID0btf16251625161658165700lztext_neneqselneqjoinsel ));
690+
DATA(insertOID=1659 ("<"PGUID0btf16251625161661166200lztext_ltintltselintltjoinsel ));
691+
DATA(insertOID=1660 ("<="PGUID0btf16251625161662166100lztext_leintltselintltjoinsel ));
692+
DATA(insertOID=1661 (">"PGUID0btf16251625161659166000lztext_gtintgtselintgtjoinsel ));
693+
DATA(insertOID=1662 (">="PGUID0btf16251625161660165900lztext_geintgtselintgtjoinsel ));
694+
687695

688696
/*
689697
* function prototypes

‎src/include/catalog/pg_proc.h

Lines changed: 37 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
88
* Portions Copyright (c) 1994, Regents of the University of California
99
*
10-
* $Id: pg_proc.h,v 1.125 2000/02/2402:05:27 tgl Exp $
10+
* $Id: pg_proc.h,v 1.126 2000/02/27 12:02:33 wieck Exp $
1111
*
1212
* NOTES
1313
* The script catalog/genbki.sh reads this file and generates .bki
@@ -2352,6 +2352,42 @@ DESCR("(internal)");
23522352
DATA(insertOID=1787 (int2PGUID11ftt1f21"1700"10000100numeric_int2- ));
23532353
DESCR("(internal)");
23542354

2355+
/* OID's 1625 - 1639 LZTEXT data type */
2356+
DATA(insertOID=1626 (lztextinPGUID11ftt1f1625"0"10000100lztextin- ));
2357+
DESCR("(internal)");
2358+
DATA(insertOID=1627 (lztextoutPGUID11ftt1f23"0"10000100lztextout- ));
2359+
DESCR("(internal)");
2360+
DATA(insertOID=1628 (lztext_textPGUID11ftt1f25"1625"10000100lztext_text-));
2361+
DESCR("convert lztext to text");
2362+
DATA(insertOID=1629 (textPGUID11ftt1f25"1625"10000100lztext_text-));
2363+
DESCR("convert lztext to text");
2364+
DATA(insertOID=1630 (text_lztextPGUID11ftt1f1625"25"10000100text_lztext-));
2365+
DESCR("convert text to lztext");
2366+
DATA(insertOID=1631 (lztextPGUID11ftt1f1625"25"10000100text_lztext-));
2367+
DESCR("convert text to lztext");
2368+
DATA(insertOID=1632 (lztextlenPGUID11ftt1f23"1625"100010lztextlen- ));
2369+
DESCR("length");
2370+
DATA(insertOID=1633 (lengthPGUID11ftt1f23"1625"100010lztextlen- ));
2371+
DESCR("length");
2372+
DATA(insertOID=1634 (lztextoctetlenPGUID11ftt1f23"1625"100010lztextoctetlen- ));
2373+
DESCR("octet length");
2374+
DATA(insertOID=1635 (octet_lengthPGUID11ftt1f23"1625"100010lztextoctetlen- ));
2375+
DESCR("octet length");
2376+
DATA(insertOID=1636 (lztext_cmpPGUID11ftt2f23"1625 1625"100010lztext_cmp- ));
2377+
DESCR("compare lztext vs. lztext");
2378+
DATA(insertOID=1637 (lztext_eqPGUID11ftt2f16"1625 1625"100010lztext_eq- ));
2379+
DESCR("equal");
2380+
DATA(insertOID=1638 (lztext_nePGUID11ftt2f16"1625 1625"100010lztext_ne- ));
2381+
DESCR("not equal");
2382+
DATA(insertOID=1639 (lztext_gtPGUID11ftt2f16"1625 1625"100010lztext_gt- ));
2383+
DESCR("greater-than");
2384+
DATA(insertOID=1664 (lztext_gePGUID11ftt2f16"1625 1625"100010lztext_ge- ));
2385+
DESCR("greater-than-or-equal");
2386+
DATA(insertOID=1665 (lztext_ltPGUID11ftt2f16"1625 1625"100010lztext_lt- ));
2387+
DESCR("lower-than");
2388+
DATA(insertOID=1656 (lztext_lePGUID11ftt2f16"1625 1625"100010lztext_le- ));
2389+
DESCR("lower-than-or-equal");
2390+
23552391
/* formatting */
23562392
DATA(insertOID=1770 (to_charPGUID11ftf2f25"1184 25"10000100timestamp_to_char- ));
23572393
DESCR("convert / formatting timestamp to text");

‎src/include/catalog/pg_rewrite.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
99
* Portions Copyright (c) 1994, Regents of the University of California
1010
*
11-
* $Id: pg_rewrite.h,v 1.10 2000/01/26 05:57:58 momjian Exp $
11+
* $Id: pg_rewrite.h,v 1.11 2000/02/27 12:02:34 wieck Exp $
1212
*
1313
* NOTES
1414
* the genbki.sh script reads this file and generates .bki
@@ -38,8 +38,8 @@ CATALOG(pg_rewrite)
3838
Oidev_class;
3939
int2ev_attr;
4040
boolis_instead;
41-
textev_qual;
42-
textev_action;
41+
lztextev_qual;
42+
lztextev_action;
4343
}FormData_pg_rewrite;
4444

4545
/* ----------------

‎src/include/catalog/pg_type.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
99
* Portions Copyright (c) 1994, Regents of the University of California
1010
*
11-
* $Id: pg_type.h,v 1.83 2000/02/21 03:36:57 tgl Exp $
11+
* $Id: pg_type.h,v 1.84 2000/02/27 12:02:34 wieck Exp $
1212
*
1313
* NOTES
1414
* the genbki.sh script reads this file and generates .bki
@@ -383,6 +383,10 @@ DATA(insert OID = 1700 ( numeric PGUID -1 -1 f b t \054 0 0 numeric_in nume
383383
DESCR("numeric(precision, decimal), arbitrary precision number");
384384
#defineNUMERICOID1700
385385

386+
/* OIDS 1625 - 1639 */
387+
DATA(insertOID=1625 (lztextPGUID-1-1fbt \05400lztextinlztextoutlztextinlztextouti_null_ ));
388+
DESCR("variable-length string, stored compressed");
389+
#defineLZTEXTOID 1625
386390

387391
#defineVARLENA_FIXED_SIZE(attr)((attr)->atttypid == BPCHAROID && (attr)->atttypmod > 0)
388392

‎src/include/utils/builtins.h

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
88
* Portions Copyright (c) 1994, Regents of the University of California
99
*
10-
* $Id: builtins.h,v 1.104 2000/02/2402:05:24 tgl Exp $
10+
* $Id: builtins.h,v 1.105 2000/02/27 12:02:34 wieck Exp $
1111
*
1212
* NOTES
1313
* This should normally only be included by fmgr.h.
@@ -35,6 +35,7 @@
3535
#include"utils/timestamp.h"
3636
#include"utils/nabstime.h"
3737
#include"utils/date.h"
38+
#include"utils/lztext.h"
3839

3940
/*
4041
*Defined in adt/
@@ -558,6 +559,21 @@ extern float32numeric_float4(Numeric num);
558559
externNumericfloat8_numeric(float64val);
559560
externfloat64numeric_float8(Numericnum);
560561

562+
/* lztext.c */
563+
lztext*lztextin(char*str);
564+
char*lztextout(lztext*lz);
565+
text*lztext_text(lztext*lz);
566+
lztext*text_lztext(text*txt);
567+
int32lztextlen(lztext*lz);
568+
int32lztextoctetlen(lztext*lz);
569+
int32lztext_cmp(lztext*lz1,lztext*lz2);
570+
boollztext_eq(lztext*lz1,lztext*lz2);
571+
boollztext_ne(lztext*lz1,lztext*lz2);
572+
boollztext_gt(lztext*lz1,lztext*lz2);
573+
boollztext_ge(lztext*lz1,lztext*lz2);
574+
boollztext_lt(lztext*lz1,lztext*lz2);
575+
boollztext_le(lztext*lz1,lztext*lz2);
576+
561577
/* ri_triggers.c */
562578
externHeapTupleRI_FKey_check_ins(FmgrInfo*proinfo);
563579
externHeapTupleRI_FKey_check_upd(FmgrInfo*proinfo);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp