From: Tom Lane <tgl@sss.pgh.pa.us>
To: darcy@druid.net
Cc: Phuong Ma <pma@commandprompt.com>
Cc: Postgres SQL <pgsql-sql@postgresql.org>
Subject: Re: Shortcut?
Date: Wed, 30 May 2001 00:21:38 -0400
Message-ID: <20797.991196498@sss.pgh.pa.us> (raw)
In-Reply-To: <20010530011951.7BA4F1A91@druid.net>
References: <20010530011951.7BA4F1A91@druid.net>
darcy@druid.net (D'Arcy J.M. Cain) writes:
> Thus spake Phuong Ma
>> SELECT distributors.* WHERE name = 'Westwood';
>> I tried it on tables in our database, but it doesn't work. Is that part
>> of earlier versions of Postgres?
> I assume you mean this.
> SELECT distributors.* WHERE distributors.name = 'Westwood';
Yes: you must mention a table in FROM to make its field names available
for reference without qualification. I think we may have tightened that
in recent releases --- the current political climate is to discourage
use of tables without FROM, since SQL92 doesn't allow it at all.
> Can you tell me where you found that example. I couldn't find it in the
> documentation sources.
A quick glimpse shows that we still have it in ref/select.sgml (try
'Westward' instead of 'Westwood'). Will fix.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: tgl@sss.pgh.pa.us, darcy@druid.net, pma@commandprompt.com
Subject: Re: Shortcut?
In-Reply-To: <20797.991196498@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
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