diff options
author | Bruce Momjian <bruce@momjian.us> | 2002-08-22 04:45:11 +0000 |
---|---|---|
committer | Bruce Momjian <bruce@momjian.us> | 2002-08-22 04:45:11 +0000 |
commit | a334ae3f2237d55369ac4b5cd6e9dbc2d35ab76d (patch) | |
tree | 597478b696d51a402db7938be648d43fcceed92d /src/backend/utils/adt/like.c | |
parent | c7e767293713cde41fb5f7ab11166ad6d22d9704 (diff) | |
download | postgresql-a334ae3f2237d55369ac4b5cd6e9dbc2d35ab76d.tar.gz |
As suggested by Tom, this patch restricts the right-hand argument of
bytealike to TEXT.
This leaves like_escape_bytea() without anything to do, but I left it in
place in anticipation of the eventual bytea pattern selectivity
functions. If there is agreement that this would be the best long term
solution, I'll take it as a TODO for 7.4.
Joe Conway
Diffstat (limited to 'src/backend/utils/adt/like.c')
-rw-r--r-- | src/backend/utils/adt/like.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/utils/adt/like.c b/src/backend/utils/adt/like.c index c55538b1e3..1ce4de6d99 100644 --- a/src/backend/utils/adt/like.c +++ b/src/backend/utils/adt/like.c @@ -11,7 +11,7 @@ * Portions Copyright (c) 1994, Regents of the University of California * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/utils/adt/like.c,v 1.49 2002/06/20 20:29:37 momjian Exp $ + * $Header: /cvsroot/pgsql/src/backend/utils/adt/like.c,v 1.50 2002/08/22 04:45:11 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -264,7 +264,7 @@ Datum bytealike(PG_FUNCTION_ARGS) { bytea *str = PG_GETARG_BYTEA_P(0); - bytea *pat = PG_GETARG_BYTEA_P(1); + text *pat = PG_GETARG_TEXT_P(1); bool result; unsigned char *s, *p; @@ -285,7 +285,7 @@ Datum byteanlike(PG_FUNCTION_ARGS) { bytea *str = PG_GETARG_BYTEA_P(0); - bytea *pat = PG_GETARG_BYTEA_P(1); + text *pat = PG_GETARG_TEXT_P(1); bool result; unsigned char *s, *p; |