Commit 52aa7203 authored by Peter Eisentraut's avatar Peter Eisentraut

Add separate type category for bit string types, allowing mixed bit/varbit

function calls to work.
parent 8a35ac24
......@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/parser/parse_coerce.c,v 2.49 2000/11/16 22:30:27 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/parser/parse_coerce.c,v 2.50 2000/11/17 19:57:47 petere Exp $
*
*-------------------------------------------------------------------------
*/
......@@ -458,7 +458,7 @@ TypeCategory(Oid inType)
*/
case (ZPBITOID):
case (VARBITOID):
result = STRING_TYPE;
result = BITSTRING_TYPE;
break;
case (OIDOID):
......@@ -543,6 +543,10 @@ PreferredType(CATEGORY category, Oid type)
result = TEXTOID;
break;
case (BITSTRING_TYPE):
result = VARBITOID;
break;
case (NUMERIC_TYPE):
if (type == OIDOID)
result = OIDOID;
......
......@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: parse_coerce.h,v 1.24 2000/10/05 19:11:38 tgl Exp $
* $Id: parse_coerce.h,v 1.25 2000/11/17 19:57:48 petere Exp $
*
*-------------------------------------------------------------------------
*/
......@@ -23,6 +23,7 @@ typedef enum CATEGORY
UNKNOWN_TYPE,
BOOLEAN_TYPE,
STRING_TYPE,
BITSTRING_TYPE,
NUMERIC_TYPE,
DATETIME_TYPE,
TIMESPAN_TYPE,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment