Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitcff2384

Browse files
committed
Print bit values as binary strings (not hex)
1 parent7852a35 commitcff2384

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

‎src/backend/utils/adt/varbit.c

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
* Portions Copyright (c) 1994, Regents of the University of California
1010
*
1111
* IDENTIFICATION
12-
* $Header: /cvsroot/pgsql/src/backend/utils/adt/varbit.c,v 1.11 2000/11/07 11:35:16 momjian Exp $
12+
* $Header: /cvsroot/pgsql/src/backend/utils/adt/varbit.c,v 1.12 2000/11/16 21:43:28 petere Exp $
1313
*
1414
*-------------------------------------------------------------------------
1515
*/
@@ -177,6 +177,12 @@ zpbit_in(PG_FUNCTION_ARGS)
177177
Datum
178178
zpbit_out(PG_FUNCTION_ARGS)
179179
{
180+
#if1
181+
/* same as varbit output */
182+
returnvarbit_out(fcinfo);
183+
#else
184+
/* This is how one would print a hex string, in case someone wants to
185+
write a formatting function. */
180186
VarBit*s=PG_GETARG_VARBIT_P(0);
181187
char*result,
182188
*r;
@@ -207,6 +213,7 @@ zpbit_out(PG_FUNCTION_ARGS)
207213
*r='\0';
208214

209215
PG_RETURN_CSTRING(result);
216+
#endif
210217
}
211218

212219
/* zpbit()

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp