Re: ERROR: More than one tuple returned by a subselect used as an expression.

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: <mel(at)gmanmi(dot)tv>, <pgsql-novice(at)postgresql(dot)org>
Subject: Re: ERROR: More than one tuple returned by a subselect used as an expression.
Date: 2003-04-04 00:55:31
Message-ID: 200304031655.31704.josh@agliodbs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Mel,

> Thanks a lot Josh!!

You're welcome.

> I wasn't thinking too hard..
>
> but then again the 2nd option (UPDATE..SET..FROM) you gave is really
> something new to me. =)

Unlike *some* databases, PostgreSQL supports sub-selects just about anywhere;
in the SELECT, FROM, WHERE, and/or HAVING clauses. I recommend buying a good
advanced SQL book to give you and idea of the possibilities, such as Joe
Celko's "SQL for Smarties, 2nd Ed.".

--
-Josh Berkus
Aglio Database Solutions
San Francisco

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message Mel Jamero 2003-04-04 01:04:08 Re: ERROR: More than one tuple returned by a subselect used as an expression.
Previous Message Josh Berkus 2003-04-04 00:51:18 Re: question about auto increment like