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

Re: select in a LIKE?

From: Dave Page <dpage(at)vale-housing(dot)co(dot)uk>
To: "'Arsalan Zaidi'" <azaidi(at)directi(dot)com>, PostgreSQL <pgsql-interfaces(at)postgresql(dot)org>
Subject: Re: select in a LIKE?
Date: 2001-10-03 12:56:27
Message-ID: AA30E7BCCA5C1D4E88A231900F8325C00B67@dogbert.vale-housing.co.uk (view raw or flat)
Thread:
Lists: pgsql-interfaces
Does:

SELECT * FROM users WHERE name LIKE '%' || (SELECT name FROM blah LIMIT 1)

Work?

Regards, Dave.

> -----Original Message-----
> From: Arsalan Zaidi [mailto:azaidi(at)directi(dot)com] 
> Sent: 03 October 2001 08:41
> To: PostgreSQL
> Subject: [INTERFACES] select in a LIKE?
> 
> 
> Hi
> 
> Can I construct a LIKE out of a select query? Something like
> 
> select * from users where name like '%(select name from blah)'
> 
> Currently, this won't work.
> 
> --Arsalan
> -------------------------------------------------
> WAR IS PEACE
> FREEDOM IS SLAVERY
> IGNORANCE IS STRENGTH
> --1984
> 
> 
> 
> ---------------------------(end of 
> broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to 
> majordomo(at)postgresql(dot)org
> 

pgsql-interfaces by date

Next:From: Darko PrenosilDate: 2001-10-03 17:13:07
Subject:
Previous:From: Arsalan ZaidiDate: 2001-10-03 07:40:43
Subject: select in a LIKE?

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