Received: from access1.lan2wan.com (bmccoy@access1.lan2wan.com [205.177.8.10]) by hub.org (8.9.3/8.9.3) with ESMTP id QAA66168 for ; Tue, 25 May 1999 16:21:29 -0400 (EDT) (envelope-from bmccoy@access1.lan2wan.com) Received: (from bmccoy@localhost) by access1.lan2wan.com (8.8.5/) id TAA20127; Tue, 25 May 1999 19:43:38 -0400 (EDT) Date: Tue, 25 May 1999 19:43:37 -0400 (EDT) From: "Brett W. McCoy" To: JT Kirkpatrick cc: "'pgsql-sql@hub.org'" Subject: Re: [SQL] using like In-Reply-To: <01BEA6C9.7A523DC0.jt-kirkpatrick@mpsllc.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Tue, 25 May 1999, JT Kirkpatrick wrote: > i'm trying to query my database (6.4.2 through odbc ms access) to find all > records matching a "like" statement. from psql i am trying this -- select > autoinv, company from table1 where company like 'Alice'; -- but it doesn't > work! i could run whatever works in psql as a passthrough query in > access97, if i could get it to work in psql! i'd expect the query to pull You need to use the wildcard for like clauses, which is % in pgsql, but Access uses '*': select autoinv, company from table1 where company like '%Alice%'; Brett W. McCoy http://www.lan2wan.com/~bmccoy ----------------------------------------------------------------------- You probably wouldn't worry about what people think of you if you could know how seldom they do. -- Olin Miller.