aboutsummaryrefslogtreecommitdiff
path: root/src/backend/utils/adt/selfuncs.c
Commit message (Collapse)AuthorAge
...
* Tom Lane wrote:Bruce Momjian2002-09-20
| | | | | | | | | | | | | | | > I see in your recent bytea-LIKE patch > > if (datatype != BYTEAOID && pg_database_encoding_max_length() > 1) > len = pg_mbcliplen((const unsigned char *) workstr, len, len - 1); > else > len -= -1; > > Surely there's one too many minus signs in that last? Joe Conway
* pgindent run.Bruce Momjian2002-09-04
|
* Remove all traces of multibyte and locale options. Clean up commentsPeter Eisentraut2002-09-03
| | | | referring to "multibyte" where it really means character encoding.
* > Okay. When you get back to the original issue, the gold is hidden inBruce Momjian2002-09-02
| | | | | | | | | | | | > src/backend/optimizer/path/indxpath.c; see the "special indexable > operators" stuff near the bottom of that file. (It's a bit of a crock > that this code is hardwired there, and not somehow accessed through a > system catalog, but it's what we've got at the moment.) The attached patch re-enables a bytea right hand argument (as compared to a text right hand argument), and enables index usage, for bytea LIKE Joe Conway
* Remove #ifdef MULTIBYTE per hackers list discussion.Tatsuo Ishii2002-08-29
|
* Add a bunch of pseudo-types to replace the behavior formerly associatedTom Lane2002-08-22
| | | | | | with OPAQUE, as per recent pghackers discussion. I still want to do some more work on the 'cstring' pseudo-type, but I'm going to commit the bulk of the changes now before the tree starts shifting under me ...
* Update copyright to 2002.Bruce Momjian2002-06-20
|
* Make initdb print a message about which locale it is about to use.Peter Eisentraut2002-05-09
| | | | | Re-add warning if the locale prevents LIKE-optimization. Done within initdb now.
* Implement types regprocedure, regoper, regoperator, regclass, regtypeTom Lane2002-04-25
| | | | | | | per pghackers discussion. Add some more typsanity tests, and clean up some problems exposed thereby (broken or missing array types for some built-in types). Also, clean up loose ends from unknownin/out patch.
* Support alternate storage scheme of 64-bit integer for date/time types.Thomas G. Lockhart2002-04-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use "--enable-integer-datetimes" in configuration to use this rather than the original float8 storage. I would recommend the integer-based storage for any platform on which it is available. We perhaps should make this the default for the production release. Change timezone(timestamptz) results to return timestamp rather than a character string. Formerly, we didn't have a way to represent timestamps with an explicit time zone other than freezing the info into a string. Now, we can reasonably omit the explicit time zone from the result and return a timestamp with values appropriate for the specified time zone. Much cleaner, and if you need the time zone in the result you can put it into a character string pretty easily anyway. Allow fractional seconds in date/time types even for dates prior to 1BC. Limit timestamp data types to 6 decimal places of precision. Just right for a micro-second storage of int8 date/time types, and reduces the number of places ad-hoc rounding was occuring for the float8-based types. Use lookup tables for precision/rounding calculations for timestamp and interval types. Formerly used pow() to calculate the desired value but with a more limited range there is no reason to not type in a lookup table. Should be *much* better performance, though formerly there were some optimizations to help minimize the number of times pow() was called. Define a HAVE_INT64_TIMESTAMP variable. Based on the configure option "--enable-integer-datetimes" and the existing internal INT64_IS_BUSTED. Add explicit date/interval operators and functions for addition and subtraction. Formerly relied on implicit type promotion from date to timestamp with time zone. Change timezone conversion functions for the timetz type from "timetz()" to "timezone()". This is consistant with other time zone coersion functions for other types. Bump the catalog version to 200204201. Fix up regression tests to reflect changes in fractional seconds representation for date/times in BC eras. All regression tests pass on my Linux box.
* Operators live in namespaces. CREATE/DROP/COMMENT ON OPERATOR takeTom Lane2002-04-16
| | | | | | | | | | qualified operator names directly, for example CREATE OPERATOR myschema.+ ( ... ). To qualify an operator name in an expression you need to write OPERATOR(myschema.+) (thanks to Peter for suggesting an escape hatch). I also took advantage of having to reformat pg_operator to fix something that'd been bugging me for a while: mergejoinable operators should have explicit links to the associated cross-data-type comparison operators, rather than hardwiring an assumption that they are named < and >.
* Locale support is on by default. The choice of locale is done in initdbPeter Eisentraut2002-04-03
| | | | and/or with GUC variables.
* TODO item done:Bruce Momjian2002-03-08
| | | | * Change FIXED_CHAR_SEL to 0.20 from 0.04 to give better selectivity (Bruce)
* Commit to match discussed elog() changes. Only update is that LOG isBruce Momjian2002-03-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | now just below FATAL in server_min_messages. Added more text to highlight ordering difference between it and client_min_messages. --------------------------------------------------------------------------- REALLYFATAL => PANIC STOP => PANIC New INFO level the prints to client by default New LOG level the prints to server log by default Cause VACUUM information to print only to the client NOTICE => INFO where purely information messages are sent DEBUG => LOG for purely server status messages DEBUG removed, kept as backward compatible DEBUG5, DEBUG4, DEBUG3, DEBUG2, DEBUG1 added DebugLvl removed in favor of new DEBUG[1-5] symbols New server_min_messages GUC parameter with values: DEBUG[5-1], INFO, NOTICE, ERROR, LOG, FATAL, PANIC New client_min_messages GUC parameter with values: DEBUG[5-1], LOG, INFO, NOTICE, ERROR, FATAL, PANIC Server startup now logged with LOG instead of DEBUG Remove debug_level GUC parameter elog() numbers now start at 10 Add test to print error message if older elog() values are passed to elog() Bootstrap mode now has a -d that requires an argument, like postmaster
* Teach planner about the idea that a mergejoin won't necessarily readTom Lane2002-03-01
| | | | | | both input streams to the end. If one variable's range is much less than the other, an indexscan-based merge can win by not scanning all of the other table. Per example from Reinhard Max.
* Guard against roundoff errors in new selectivity-estimation code,Tom Lane2002-01-03
| | | | per bug report from Laurette Cisneros.
* New pgindent run with fixes suggested by Tom. Patch manually reviewed,Bruce Momjian2001-11-05
| | | | initdb/regression tests pass.
* Another pgindent run. Fixes enum indenting, and improves #endifBruce Momjian2001-10-28
| | | | spacing. Also adds space for one-line comments.
* pgindent run on all C files. Java run to follow. initdb/regressionBruce Momjian2001-10-25
| | | | tests pass.
* Make selectivity routines cope gracefully with NaNs, infinities, andTom Lane2001-10-13
| | | | | NUMERIC values that are out of the range of 'double'. Per trouble report from Mike Quinn.
* Add missing TIMESTAMPTZ case.Tom Lane2001-10-03
|
* > Here's a revised patch. Changes:Bruce Momjian2001-09-14
| | | | | | | | | | | | | | | | | | | | | | | | > > 1. Now outputs '\\' instead of '\134' when using encode(bytea, 'escape') > Note that I ended up leaving \0 as \000 so that there are no ambiguities > when decoding something like, for example, \0123. > > 2. Fixed bug in byteain which allowed input values which were not valid > octals (e.g. \789), to be parsed as if they were octals. > > Joe > Here's rev 2 of the bytea string support patch. Changes: 1. Added missing declaration for MatchBytea function 2. Added PQescapeBytea to fe-exec.c 3. Applies cleanly on cvs tip from this afternoon I'm hoping that someone can review/approve/apply this before beta starts, so I guess I'd vote (not that it counts for much) to delay beta a few days :-) Joe Conway
* Add comparison operators and btree indexing support for type bytea.Tom Lane2001-08-13
| | | | From Joe Conway.
* Partial indexes work again, courtesy of Martijn van Oosterhout.Tom Lane2001-07-16
| | | | | | Note: I didn't force an initdb, figuring that one today was enough. However, there is a new function in pg_proc.h, and pg_dump won't be able to dump partial indexes until you add that function.
* Optimizer can now estimate selectivity of IS NULL, IS NOT NULL,Tom Lane2001-06-25
| | | | | | | | IS TRUE, etc, with some degree of verisimilitude. Split out selectivity support functions from builtins.h into a new header file selfuncs.h, so as to reduce the number of header files builtins.h must depend on. Fix a few missing inclusions exposed thereby. From Joe Conway, with some kibitzing from Tom Lane.
* Teach convert_to_scalar about datatypes timetz, inet, cidr, macaddr.Tom Lane2001-06-09
|
* Further work on making use of new statistics in planner. Adjust APIsTom Lane2001-06-05
| | | | | | | | | of costsize.c routines to pass Query root, so that costsize can figure more things out by itself and not be so dependent on its callers to tell it everything it needs to know. Use selectivity of hash or merge clause to estimate number of tuples processed internally in these joins (this is more useful than it would've been before, since eqjoinsel is somewhat more accurate than before).
* Fix eqjoinsel() to make use of new statistics.Tom Lane2001-05-27
|
* Modify optimizer data structures so that IndexOptInfo lists built forTom Lane2001-05-20
| | | | | | | | create_index_paths are not immediately discarded, but are available for subsequent planner work. This allows avoiding redundant syscache lookups in several places. Change interface to operator selectivity estimation procedures to allow faster and more flexible estimation. Initdb forced due to change of pg_proc entries for selectivity functions!
* First cut at making indexscan cost estimates depend on correlationTom Lane2001-05-09
| | | | between index order and table order.
* Rewrite of planner statistics-gathering code. ANALYZE is now available asTom Lane2001-05-07
| | | | | | | | | | | | | | | | | a separate statement (though it can still be invoked as part of VACUUM, too). pg_statistic redesigned to be more flexible about what statistics are stored. ANALYZE now collects a list of several of the most common values, not just one, plus a histogram (not just the min and max values). Random sampling is used to make the process reasonably fast even on very large tables. The number of values and histogram bins collected is now user-settable via an ALTER TABLE command. There is more still to do; the new stats are not being used everywhere they could be in the planner. But the remaining changes for this project should be localized, and the behavior is already better than before. A not-very-related change is that sorting now makes use of btree comparison routines if it can find one, rather than invoking '<' twice.
* Fix comments that were mis-wrapped, for Tom Lane.Bruce Momjian2001-03-23
|
* pgindent run. Make it all clean.Bruce Momjian2001-03-22
|
* Change Copyright from PostgreSQL, Inc to PostgreSQL Global Development Group.Bruce Momjian2001-01-24
|
* Ensure that all uses of <ctype.h> functions are applied to unsigned-charTom Lane2000-12-03
| | | | | values, whether the local char type is signed or not. This is necessary for portability. Per discussion on pghackers around 9/16/00.
* Store current LC_COLLATE and LC_CTYPE settings in pg_control during initdb;Tom Lane2000-11-25
| | | | | | | | | | re-adopt these settings at every postmaster or standalone-backend startup. This should fix problems with indexes becoming corrupt due to failure to provide consistent locale environment for postmaster at all times. Also, refuse to start up a non-locale-enabled compilation in a database originally initdb'd with a non-C locale. Suppress LIKE index optimization if locale is not "C" or "POSIX" (are there any other locales where it's safe?). Issue NOTICE during initdb if selected locale disables LIKE optimization.
* Change SearchSysCache coding conventions so that a reference count isTom Lane2000-11-16
| | | | | | | maintained for each cache entry. A cache entry will not be freed until the matching ReleaseSysCache call has been executed. This eliminates worries about cache entries getting dropped while still in use. See my posting to pg-hackers of even date for more info.
* Use SearchSysCacheTupleCopy() instead of SearchSysCacheTuple() inHiroshi Inoue2000-11-10
| | | | | order to continue to access the tuple more than now. This would resolve a segmentation fault error.
* Add proofreader's changes to docs.Bruce Momjian2000-10-05
| | | | Fix misspelling of disbursion to dispersion.
* Reimplement LIKE/ESCAPE as operators so that indexscan optimizationTom Lane2000-09-15
| | | | | can still work, per recent discussion on pghackers. Correct some bugs in ILIKE implementation.
* More functions updated to new fmgr style --- money, name, tid datatypes.Tom Lane2000-08-03
| | | | | We're reaching the mopup stage here (good thing too, this is getting tedious).
* Repair bug noted by Paul Caskey: neqsel() has been generating a bogusTom Lane2000-08-03
| | | | | | | | | result, in fact nearly the opposite of what it should, because it was passing the not-equal operator to eqsel() which would use it to compare the value against the most common value in the column, and of course obtain the wrong result therefrom. Must pass the equality operator to eqsel() instead. Fortunately that's easy to get from the oprnegate link.
* bpchar, varchar, bytea, numeric are toastable --- if you initdb, whichTom Lane2000-07-29
| | | | | | I did not force. I marked numeric as compressable-but-not-move-off-able, partly to test that storage mode and partly because I've got doubts that numerics are large enough to need external storage.
* Functions on 'text' type updated to new fmgr style. 'text' isTom Lane2000-07-06
| | | | now TOAST-able.
* Update textin() and textout() to new fmgr style. This is just phaseTom Lane2000-07-05
| | | | | one of updating the whole text datatype, but there are so dang many calls of these two routines that it seems worth a separate commit.
* Clean up #include's.Bruce Momjian2000-06-15
|
* Big warnings cleanup for Solaris/GCC. Down to about 40 now, butPeter Eisentraut2000-06-14
| | | | | | | | | | | we'll get there one day. Use `cat' to create aclocal.m4, not `aclocal'. Some people don't have automake installed. Only run the autoconf rule in the top-level GNUmakefile if the invoker specified `make configure', don't run it automatically because of CVS timestamp skew.
* I had overlooked the fact that some fmgr-callable functions return voidTom Lane2000-06-14
| | | | | | --- ie, they're only called for side-effects. Add a PG_RETURN_VOID() macro and use it where appropriate. This probably doesn't change the machine code by a single bit ... it's just for documentation.
* Another round of updates for new fmgr, mostly in the datetime code.Tom Lane2000-06-09
|
* Latest round of fmgr updates. All functions with bool,char, or int2Tom Lane2000-06-05
| | | | | | | inputs have been converted to newstyle. This should go a long way towards fixing our portability problems with platforms where char and short parameters are passed differently from int-width parameters. Still more to do for the Alpha port however.