From cff23842a4c68301ddf34559c7af383bb5557054 Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Thu, 16 Nov 2000 21:43:28 +0000 Subject: [PATCH] Print bit values as binary strings (not hex) --- src/backend/utils/adt/varbit.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/backend/utils/adt/varbit.c b/src/backend/utils/adt/varbit.c index a8b8ceb994..704e737b94 100644 --- a/src/backend/utils/adt/varbit.c +++ b/src/backend/utils/adt/varbit.c @@ -9,7 +9,7 @@ * Portions Copyright (c) 1994, Regents of the University of California * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/utils/adt/varbit.c,v 1.11 2000/11/07 11:35:16 momjian Exp $ + * $Header: /cvsroot/pgsql/src/backend/utils/adt/varbit.c,v 1.12 2000/11/16 21:43:28 petere Exp $ * *------------------------------------------------------------------------- */ @@ -177,6 +177,12 @@ zpbit_in(PG_FUNCTION_ARGS) Datum zpbit_out(PG_FUNCTION_ARGS) { +#if 1 + /* same as varbit output */ + return varbit_out(fcinfo); +#else +/* This is how one would print a hex string, in case someone wants to + write a formatting function. */ VarBit *s = PG_GETARG_VARBIT_P(0); char *result, *r; @@ -207,6 +213,7 @@ zpbit_out(PG_FUNCTION_ARGS) *r = '\0'; PG_RETURN_CSTRING(result); +#endif } /* zpbit() -- 2.40.0