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
7528fd2d
Commit
7528fd2d
authored
Feb 10, 2000
by
Bruce Momjian
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add btree indexing of boolean values
Don Baccus
parent
ede72c28
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
53 additions
and
10 deletions
+53
-10
src/backend/access/nbtree/nbtcompare.c
src/backend/access/nbtree/nbtcompare.c
+7
-1
src/backend/utils/adt/bool.c
src/backend/utils/adt/bool.c
+13
-1
src/include/catalog/pg_amop.h
src/include/catalog/pg_amop.h
+11
-1
src/include/catalog/pg_amproc.h
src/include/catalog/pg_amproc.h
+2
-1
src/include/catalog/pg_opclass.h
src/include/catalog/pg_opclass.h
+3
-1
src/include/catalog/pg_operator.h
src/include/catalog/pg_operator.h
+5
-3
src/include/catalog/pg_proc.h
src/include/catalog/pg_proc.h
+8
-1
src/include/utils/builtins.h
src/include/utils/builtins.h
+4
-1
No files found.
src/backend/access/nbtree/nbtcompare.c
View file @
7528fd2d
...
...
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtcompare.c,v 1.3
2 2000/01/28 17:23:47
momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtcompare.c,v 1.3
3 2000/02/10 19:51:38
momjian Exp $
*
* NOTES
* These functions are stored in pg_amproc. For each operator class
...
...
@@ -207,3 +207,9 @@ bttextcmp(struct varlena * a, struct varlena * b)
else
return
1
;
}
int32
btboolcmp
(
bool
a
,
bool
b
)
{
return
(
int32
)
((
uint8
)
a
-
(
uint8
)
b
);
}
src/backend/utils/adt/bool.c
View file @
7528fd2d
...
...
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/bool.c,v 1.2
1 2000/01/26 05:57:13
momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/utils/adt/bool.c,v 1.2
2 2000/02/10 19:51:39
momjian Exp $
*
*-------------------------------------------------------------------------
*/
...
...
@@ -119,6 +119,18 @@ boolgt(bool arg1, bool arg2)
return
arg1
>
arg2
;
}
bool
boolle
(
bool
arg1
,
bool
arg2
)
{
return
arg1
<=
arg2
;
}
bool
boolge
(
bool
arg1
,
bool
arg2
)
{
return
arg1
>=
arg2
;
}
bool
istrue
(
bool
arg1
)
{
...
...
src/include/catalog/pg_amop.h
View file @
7528fd2d
...
...
@@ -8,7 +8,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: pg_amop.h,v 1.
29 2000/01/26 05:57:56
momjian Exp $
* $Id: pg_amop.h,v 1.
30 2000/02/10 19:51:42
momjian Exp $
*
* NOTES
* the genbki.sh script reads this file and generates .bki
...
...
@@ -344,6 +344,16 @@ DATA(insert OID = 0 ( 403 1768 1752 3 ));
DATA
(
insert
OID
=
0
(
403
1768
1757
4
));
DATA
(
insert
OID
=
0
(
403
1768
1756
5
));
/*
* nbtree bool
*/
DATA
(
insert
OID
=
0
(
403
1690
58
1
));
DATA
(
insert
OID
=
0
(
403
1690
1694
2
));
DATA
(
insert
OID
=
0
(
403
1690
91
3
));
DATA
(
insert
OID
=
0
(
403
1690
1695
4
));
DATA
(
insert
OID
=
0
(
403
1690
59
5
));
/*
* hash table _ops
*/
...
...
src/include/catalog/pg_amproc.h
View file @
7528fd2d
...
...
@@ -10,7 +10,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: pg_amproc.h,v 1.
19 2000/01/26 05:57:56
momjian Exp $
* $Id: pg_amproc.h,v 1.
20 2000/02/10 19:51:45
momjian Exp $
*
* NOTES
* the genbki.sh script reads this file and generates .bki
...
...
@@ -99,6 +99,7 @@ DATA(insert OID = 0 (403 810 836 1));
DATA
(
insert
OID
=
0
(
403
935
926
1
));
DATA
(
insert
OID
=
0
(
403
652
926
1
));
DATA
(
insert
OID
=
0
(
403
1768
1769
1
));
DATA
(
insert
OID
=
0
(
403
1690
1693
1
));
/* hash */
...
...
src/include/catalog/pg_opclass.h
View file @
7528fd2d
...
...
@@ -8,7 +8,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: pg_opclass.h,v 1.2
7 2000/01/26 05:57:57
momjian Exp $
* $Id: pg_opclass.h,v 1.2
8 2000/02/10 19:51:45
momjian Exp $
*
* NOTES
* the genbki.sh script reads this file and generates .bki
...
...
@@ -118,5 +118,7 @@ DATA(insert OID = 652 ( cidr_ops 650 ));
DESCR
(
""
);
DATA
(
insert
OID
=
1768
(
numeric_ops
1700
));
DESCR
(
""
);
DATA
(
insert
OID
=
1690
(
bool_ops
16
));
DESCR
(
""
);
#endif
/* PG_OPCLASS_H */
src/include/catalog/pg_operator.h
View file @
7528fd2d
...
...
@@ -8,7 +8,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: pg_operator.h,v 1.6
6 2000/01/26 05:57:58
momjian Exp $
* $Id: pg_operator.h,v 1.6
7 2000/02/10 19:51:45
momjian Exp $
*
* NOTES
* the genbki.sh script reads this file and generates .bki
...
...
@@ -96,11 +96,13 @@ DATA(insert OID = 76 ( ">" PGUID 0 b t f 23 20 16 418 80 0 0 int48g
DATA
(
insert
OID
=
80
(
"<="
PGUID
0
b
t
f
23
20
16
430
76
0
0
int48le
scalarltsel
scalarltjoinsel
));
DATA
(
insert
OID
=
82
(
">="
PGUID
0
b
t
f
23
20
16
420
37
0
0
int48ge
scalargtsel
scalargtjoinsel
));
DATA
(
insert
OID
=
58
(
"<"
PGUID
0
b
t
f
16
16
16
59
0
0
0
boollt
scalarltsel
scalarltjoinsel
));
DATA
(
insert
OID
=
59
(
">"
PGUID
0
b
t
f
16
16
16
58
0
0
0
boolgt
scalargtsel
scalargtjoinsel
));
DATA
(
insert
OID
=
58
(
"<"
PGUID
0
b
t
f
16
16
16
59
1695
0
0
boollt
scalarltsel
scalarltjoinsel
));
DATA
(
insert
OID
=
59
(
">"
PGUID
0
b
t
f
16
16
16
58
1694
0
0
boolgt
scalargtsel
scalargtjoinsel
));
DATA
(
insert
OID
=
85
(
"<>"
PGUID
0
b
t
f
16
16
16
85
91
0
0
boolne
neqsel
neqjoinsel
));
DATA
(
insert
OID
=
91
(
"="
PGUID
0
b
t
t
16
16
16
91
85
58
58
booleq
eqsel
eqjoinsel
));
#define BooleanEqualOperator 91
DATA
(
insert
OID
=
1694
(
"<="
PGUID
0
b
t
f
16
16
16
1695
59
0
0
boolle
scalarltsel
scalarltjoinsel
));
DATA
(
insert
OID
=
1695
(
">="
PGUID
0
b
t
f
16
16
16
1694
58
0
0
boolge
scalargtsel
scalargtjoinsel
));
DATA
(
insert
OID
=
92
(
"="
PGUID
0
b
t
t
18
18
16
92
630
631
631
chareq
eqsel
eqjoinsel
));
DATA
(
insert
OID
=
93
(
"="
PGUID
0
b
t
t
19
19
16
93
643
660
660
nameeq
eqsel
eqjoinsel
));
...
...
src/include/catalog/pg_proc.h
View file @
7528fd2d
...
...
@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: pg_proc.h,v 1.1
19 2000/01/31 14:02:27 wieck
Exp $
* $Id: pg_proc.h,v 1.1
20 2000/02/10 19:51:46 momjian
Exp $
*
* NOTES
* The script catalog/genbki.sh reads this file and generates .bki
...
...
@@ -2230,6 +2230,13 @@ DESCR("host address");
DATA
(
insert
OID
=
683
(
network
PGUID
11
f
t
t
1
f
25
"869"
100
0
0
100
network_network
-
));
DESCR
(
"network address"
);
DATA
(
insert
OID
=
1691
(
boolle
PGUID
11
f
t
t
2
f
16
"16 16"
100
0
0
100
boolle
-
));
DESCR
(
"less-than-or-equal"
);
DATA
(
insert
OID
=
1692
(
boolge
PGUID
11
f
t
t
2
f
16
"16 16"
100
0
0
100
boolge
-
));
DESCR
(
"greater-than-or-equal"
);
DATA
(
insert
OID
=
1693
(
btboolcmp
PGUID
11
f
t
t
2
f
23
"16 16"
100
0
0
100
btboolcmp
-
));
DESCR
(
"btree less-equal-greater"
);
/* OID's 1700 - 1799 NUMERIC data type */
DATA
(
insert
OID
=
1701
(
numeric_in
PGUID
11
f
t
t
3
f
1700
"0 0 23"
100
0
0
100
numeric_in
-
));
DESCR
(
"(internal)"
);
...
...
src/include/utils/builtins.h
View file @
7528fd2d
...
...
@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: builtins.h,v 1.
99 2000/01/26 05:58:37
momjian Exp $
* $Id: builtins.h,v 1.
100 2000/02/10 19:51:52
momjian Exp $
*
* NOTES
* This should normally only be included by fmgr.h.
...
...
@@ -44,6 +44,8 @@ extern bool booleq(bool arg1, bool arg2);
extern
bool
boolne
(
bool
arg1
,
bool
arg2
);
extern
bool
boollt
(
bool
arg1
,
bool
arg2
);
extern
bool
boolgt
(
bool
arg1
,
bool
arg2
);
extern
bool
boolle
(
bool
arg1
,
bool
arg2
);
extern
bool
boolge
(
bool
arg1
,
bool
arg2
);
extern
bool
istrue
(
bool
arg1
);
extern
bool
isfalse
(
bool
arg1
);
...
...
@@ -181,6 +183,7 @@ extern int32 btabstimecmp(AbsoluteTime a, AbsoluteTime b);
extern
int32
btcharcmp
(
char
a
,
char
b
);
extern
int32
btnamecmp
(
NameData
*
a
,
NameData
*
b
);
extern
int32
bttextcmp
(
struct
varlena
*
a
,
struct
varlena
*
b
);
extern
int32
btboolcmp
(
bool
a
,
bool
b
);
/* support routines for the rtree access method, by opclass */
extern
BOX
*
rt_box_union
(
BOX
*
a
,
BOX
*
b
);
...
...
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