Re: SQL Join - MySQL/PostgreSQL difference?

From: Brice Ruth <brice(at)webprojkt(dot)com>
To: pgsql-general(at)postgresql(dot)org(dot)pgsql-sql(at)postgresql(dot)org
Subject: Re: SQL Join - MySQL/PostgreSQL difference?
Date: 2001-02-02 14:41:01
Message-ID: 3A7AC6FD.2654BB94@webprojkt.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-sql

Ian,

Thanx - I figured the same about the ambiguity. I'll keep tryin' to
debug this with the vendor, then.

-Brice

Ian Harding wrote:
>
> Brice Ruth wrote:
>
> > Greetings.
> >
> > I'm working with a product provided by a third part that interfaces to
> > data housed in a database of your choice. Previously, my choice was
> > MySQL - apparently it handled certain queries too slowly, so I'm giving
> > PostgreSQL a shot. Here's the query:
> >
> > SELECT
> > a.Number,
> > a.Code,
> > a.Text
> > FROM
> > b,
> > a
> > WHERE
> > (b.Id = a.Id) AND
> > (VersionId = 'key1') AND
> > (Category = 'key2') AND
> > (b.d_Id = 'key3')
> > ORDER BY
> > a.Number;
> >
> > (my apologies: I had to 'mangle' the table/column names because of NDA)
> >
> > So my question is this: would this query operate differently in MySQL
> > than in PostgreSQL? The reason I ask is that this query in MySQL
> > returns results, yet in PostgreSQL it does not. I read a post about
> > PostgreSQL not supporting outer joins, but I don't have enough
> > experience with SQL to determine if this is such a query or not. Please
> >
> > advise.
> >
> > Any help will be (as always) sincerely appreciated.
> >
> > --
> > Brice Ruth
> > WebProjkt, Inc.
> > VP, Director of Internet Technology
> > http://www.webprojkt.com/
>
> It should work the same in both. The only thing I notice is that not all
> the field names are qualified with table names or aliases. That can lead
> to ambiguity, but the query would blow up on both databases if that were a
> problem.
>
> Ian

--
Brice Ruth
WebProjkt, Inc.
VP, Director of Internet Technology
http://www.webprojkt.com/

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Brett W. McCoy 2001-02-02 14:41:48 Re: Installing Postgresql 7 on either RaQ3i or RaQ2
Previous Message <No Name> 2001-02-02 14:32:28 Re: Foreign Keys

Browse pgsql-sql by date

  From Date Subject
Next Message Peter Eisentraut 2001-02-02 14:46:44 Re: binary operators
Previous Message doj 2001-02-02 13:22:13 const cast ?