pg.ddx.io  pgsql-interfaces@postgresql.org mailing list archive  
help / color / mirror / Atom feed
select in a LIKE?
2+ messages / 2 participants
[nested] [flat]

* select in a LIKE?
@ 2001-10-03 07:40  Arsalan Zaidi <azaidi@directi.com>
  0 siblings, 0 replies; 2+ messages in thread

From: Arsalan Zaidi @ 2001-10-03 07:40 UTC (permalink / raw)
  To: pgsql-interfaces

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





^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: select in a LIKE?
@ 2001-10-03 12:56  Dave Page <dpage@vale-housing.co.uk>
  0 siblings, 0 replies; 2+ messages in thread

From: Dave Page @ 2001-10-03 12:56 UTC (permalink / raw)
  To: 'Arsalan Zaidi' <azaidi@directi.com>; 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@directi.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@postgresql.org
> 



^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2001-10-03 12:56 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2001-10-03 07:40 select in a LIKE? Arsalan Zaidi <azaidi@directi.com>
2001-10-03 12:56 Re: select in a LIKE? Dave Page <dpage@vale-housing.co.uk>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox