Re: How do I upsert depending on a second table?

From: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
To: Samuel Marks <samuelmarks(at)gmail(dot)com>
Cc: pgsql-general(at)lists(dot)postgresql(dot)org
Subject: Re: How do I upsert depending on a second table?
Date: 2025-09-23 21:00:50
Message-ID: a31acf07-0ff7-4be3-8235-e4151edc4208@aklaver.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 9/23/25 13:56, Samuel Marks wrote:
> the AS syntax can alternatively be used for aliases
> https://www.postgresql.org/docs/current/sql-select.html
>
> `SELECT actual_tablename table0 WHERE table0.column00 = 1`

Ok, I missed the:

... FROM org org_tbl ...
>
> (I used a space)

Yeah, I use tbl_name AS alias_name to help these old eyes catch this
sort of thing in my queries.

--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Samuel Marks 2025-09-23 21:02:38 Re: How do I upsert depending on a second table?
Previous Message Adrian Klaver 2025-09-23 20:57:53 Re: How do I upsert depending on a second table?