| From: | Christof Glaser <gcg(at)gl(dot)aser(dot)de> |
|---|---|
| To: | olle(dot)wijk(at)systecon(dot)se (Olle Wijk), pgsql-sql(at)postgresql(dot)org |
| Subject: | Re: How do I extract ONE particular field, when multiple table contain the same field name? |
| Date: | 2001-09-14 21:05:21 |
| Message-ID: | 20010914211433.26D8112BF8@pinguin.gl.aser.de |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-sql |
On Wednesday, 12. September 2001 11:06, Olle Wijk wrote:
> Hi,
>
> I am pretty new att using SQL-quires, could anyone help me with this
> one:
>
> I want to do the following SQL-query:
>
> Select XID, DENOM, PRICE, FRT, CTID From XItem xi, Category c Where
> xi.System=1 and xi.Category=c.Index
>
> the problem is that the field 'DENOM' is present in both table 'XItem'
> and 'Category'
Just write: table.field or table-alias.field instead of just 'field'
(like you did already in the WHERE clause):
Select XID, xi.DENOM, PRICE, FRT, CTID
>From XItem xi, Category c
Where xi.System=1 and xi.Category=c.Index
Christof
--
gl.aser . software engineering . internet service
http://gl.aser.de/ . Planckstraße 7 . D-39104 Magdeburg
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Jeff Eckermann | 2001-09-14 21:35:32 | Re: How do I extract ONE particular field, when multiple table contain the same field name? |
| Previous Message | Patrik Kudo | 2001-09-14 20:34:43 | Re: How do I extract ONE particular field, when multiple table |