mirror of
https://github.com/postgres/postgres.git
synced 2025-07-30 11:03:19 +03:00
Cause CHAR(n) to TEXT or VARCHAR conversion to automatically strip trailing
blanks, in hopes of reducing the surprise factor for newbies. Remove redundant operators for VARCHAR (it depends wholly on TEXT operations now). Clean up resolution of ambiguous operators/functions to avoid surprising choices for domains: domains are treated as equivalent to their base types and binary-coercibility is no longer considered a preference item when choosing among multiple operators/functions. IsBinaryCoercible now correctly reflects the notion that you need *only* relabel the type to get from type A to type B: that is, a domain is binary-coercible to its base type, but not vice versa. Various marginal cleanup, including merging the essentially duplicate resolution code in parse_func.c and parse_oper.c. Improve opr_sanity regression test to understand about binary compatibility (using pg_cast), and fix a couple of small errors in the catalogs revealed thereby. Restructure "special operator" handling to fetch operators via index opclasses rather than hardwiring assumptions about names (cleans up the pattern_ops stuff a little).
This commit is contained in:
@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: builtins.h,v 1.218 2003/05/23 22:33:23 tgl Exp $
|
||||
* $Id: builtins.h,v 1.219 2003/05/26 00:11:28 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -496,15 +496,6 @@ extern Datum varcharout(PG_FUNCTION_ARGS);
|
||||
extern Datum varcharrecv(PG_FUNCTION_ARGS);
|
||||
extern Datum varcharsend(PG_FUNCTION_ARGS);
|
||||
extern Datum varchar(PG_FUNCTION_ARGS);
|
||||
extern Datum varchareq(PG_FUNCTION_ARGS);
|
||||
extern Datum varcharne(PG_FUNCTION_ARGS);
|
||||
extern Datum varcharlt(PG_FUNCTION_ARGS);
|
||||
extern Datum varcharle(PG_FUNCTION_ARGS);
|
||||
extern Datum varchargt(PG_FUNCTION_ARGS);
|
||||
extern Datum varcharge(PG_FUNCTION_ARGS);
|
||||
extern Datum varcharcmp(PG_FUNCTION_ARGS);
|
||||
extern Datum varcharlen(PG_FUNCTION_ARGS);
|
||||
extern Datum varcharoctetlen(PG_FUNCTION_ARGS);
|
||||
|
||||
/* varlena.c */
|
||||
extern Datum textin(PG_FUNCTION_ARGS);
|
||||
|
@ -6,7 +6,7 @@
|
||||
* Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: lsyscache.h,v 1.69 2003/05/09 18:08:48 tgl Exp $
|
||||
* $Id: lsyscache.h,v 1.70 2003/05/26 00:11:28 tgl Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -17,6 +17,7 @@
|
||||
|
||||
extern bool op_in_opclass(Oid opno, Oid opclass);
|
||||
extern bool op_requires_recheck(Oid opno, Oid opclass);
|
||||
extern Oid get_opclass_member(Oid opclass, int16 strategy);
|
||||
extern char *get_attname(Oid relid, AttrNumber attnum);
|
||||
extern AttrNumber get_attnum(Oid relid, const char *attname);
|
||||
extern Oid get_atttype(Oid relid, AttrNumber attnum);
|
||||
|
Reference in New Issue
Block a user