mirror of
https://github.com/postgres/postgres.git
synced 2025-07-11 10:01:57 +03:00
First step in fixing selectivity-estimation code. eqsel and
neqsel now behave as per my suggestions in pghackers a few days ago. selectivity for < > <= >= should work OK for integral types as well, but still need work for nonintegral types. Since these routines have never actually executed before :-(, this may result in some significant changes in the optimizer's choices of execution plans. Let me know if you see any serious misbehavior. CAUTION: THESE CHANGES REQUIRE INITDB. pg_statistic table has changed.
This commit is contained in:
@ -6,7 +6,7 @@
|
||||
*
|
||||
* Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: builtins.h,v 1.84 1999/07/16 17:07:39 momjian Exp $
|
||||
* $Id: builtins.h,v 1.85 1999/08/01 04:54:20 tgl Exp $
|
||||
*
|
||||
* NOTES
|
||||
* This should normally only be included by fmgr.h.
|
||||
@ -372,10 +372,10 @@ extern Oid regproctooid(RegProcedure rp);
|
||||
#define RegprocToOid(rp) regproctooid(rp)
|
||||
|
||||
/* selfuncs.c */
|
||||
extern float64 eqsel(Oid opid, Oid relid, AttrNumber attno, char *value, int32 flag);
|
||||
extern float64 neqsel(Oid opid, Oid relid, AttrNumber attno, char *value, int32 flag);
|
||||
extern float64 intltsel(Oid opid, Oid relid, AttrNumber attno, int32 value, int32 flag);
|
||||
extern float64 intgtsel(Oid opid, Oid relid, AttrNumber attno, int32 value, int32 flag);
|
||||
extern float64 eqsel(Oid opid, Oid relid, AttrNumber attno, Datum value, int32 flag);
|
||||
extern float64 neqsel(Oid opid, Oid relid, AttrNumber attno, Datum value, int32 flag);
|
||||
extern float64 intltsel(Oid opid, Oid relid, AttrNumber attno, Datum value, int32 flag);
|
||||
extern float64 intgtsel(Oid opid, Oid relid, AttrNumber attno, Datum value, int32 flag);
|
||||
extern float64 eqjoinsel(Oid opid, Oid relid1, AttrNumber attno1, Oid relid2, AttrNumber attno2);
|
||||
extern float64 neqjoinsel(Oid opid, Oid relid1, AttrNumber attno1, Oid relid2, AttrNumber attno2);
|
||||
extern float64 intltjoinsel(Oid opid, Oid relid1, AttrNumber attno1, Oid relid2, AttrNumber attno2);
|
||||
|
Reference in New Issue
Block a user