Re: make == as = ?

From: Stephen Frost <sfrost(at)snowman(dot)net>
To: Josh Berkus <josh(at)agliodbs(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org, Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr>
Subject: Re: make == as = ?
Date: 2004-04-07 16:24:00
Message-ID: 20040407162400.GC7060@ns.snowman.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

* Josh Berkus (josh(at)agliodbs(dot)com) wrote:
> Were I teaching a class with a SQL component, using PostgreSQL as a tool, I
> would be very careful to avoid letting my students use an extensions to SQL;
> no "!=", no "SELECT DISTINCT ON" and no alias references in the GROUP BY
> clause.

I'd really like PostgreSQL to somehow warn me when I start doing things
like this. It's not my intent to use PostgreSQL-specific SQL in general
so when I start doing it I'd like to know. In some cases there may not
be an option, of course, but especially in cases where there's a 'right
way' I'd love for PostgreSQL to spit out a warning which tells me what
the right way is.

ie: "select * from table_name where column_name != '1';"
Warning: '!=' is not valid SQL, use '<>' instead.

This would help me, at least, write correct and portable SQL. :)

Stephen

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2004-04-07 17:04:27 Re: make == as = ?
Previous Message Fabien COELHO 2004-04-07 15:34:42 Re: make == as = ?