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

Re: join with 1 row limit

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Behringer Behringer <behringerdj(at)yahoo(dot)com>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: join with 1 row limit
Date: 2011-01-15 15:49:09
Message-ID: 28617.1295106549@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-novice
Behringer Behringer <behringerdj(at)yahoo(dot)com> writes:
> In mysql this query works fine, what is the equivalent in posgresql?
> SELECT *
> FROM 
> products p LEFT JOIN
> products_images pi ON p.id = pi.product_id  LIMIT 1
> WHERE products.company = 7

When asking that sort of question, it would be a good idea to explain
exactly what you expect that syntax to do.  Not all of us know every
nook and cranny of mysql's nonstandard behaviors.

			regards, tom lane

In response to

Responses

pgsql-novice by date

Next:From: Behringer BehringerDate: 2011-01-15 18:37:54
Subject: Re: join with 1 row limit
Previous:From: Frank BaxDate: 2011-01-15 13:19:25
Subject: Re: join with 1 row limit

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