Skip site navigation (1) Skip section navigation (2)

Re: [BUGS] like operator bug

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: jfaith <jfaith(at)cemsys(dot)com>
Cc: pgsql-bugs(at)postgreSQL(dot)org
Subject: Re: [BUGS] like operator bug
Date: 1999-09-07 19:17:46
Message-ID: 28484.936731866@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-bugs
jfaith <jfaith(at)cemsys(dot)com> writes:
> create table tst(addr char(4));
> insert into tst values('1000');
> insert into tst values('1010');
> insert into tst values('1120');
> select * from tst where addr like '1%0';
> produces
> addr
> ----
> 1120(1 row)
> where it should return all of the example rows.

I believe I have fixed this.  If you need the fix before 6.5.2 is out,
line 188 in src/backend/utils/adt/like.c should return LIKE_FALSE not
LIKE_ABORT:

  	if (*text !='\0')
! 		return LIKE_ABORT;
  	else

  	if (*text !='\0')
! 		return LIKE_FALSE;
  	else

			regards, tom lane

pgsql-bugs by date

Next:From: Patrick LoganDate: 1999-09-08 16:49:09
Subject: Problem enabling pltcl
Previous:From: Alois MaierDate: 1999-09-07 18:59:49
Subject: Set Transcation Isolation level bug

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group