Table name specified more than once

From: Alexander Mueller <Alexander(dot)Mueller(at)SurfControl(dot)com>
To: "'pgsql-general(at)postgresql(dot)org'" <pgsql-general(at)postgresql(dot)org>
Subject: Table name specified more than once
Date: 2003-06-13 15:07:28
Message-ID: 72B81E909EBF7E4FBB4353596B55CF6D2A01FB@cassini.surfcontrol.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


Hello,

I am having troubles with the following query

UPDATE "public"."Workstations" SET "Last_Access" = "c1"."Last_Access",
"First_Access" = "c1"."First_Access", "Hits" = "C1"."Hits" FROM
"public"."Workstations" INNER JOIN (select min("Access_Time") as
"First_Access", max("Access_Time") as "Last_Access", count(*) AS "Hits",
"Workstation_Id" FROM "public"."Connections" GROUP BY "Workstation_Id") C1
on "public"."Workstations"."Workstation_Id" = "c1"."Workstation_Id"

It results in a "Table name "Workstations" specified more than once" error
message. Can anyone help me with correcting the syntax?

Thank you,
Alexander

Get the latest news on SurfControl and our products, subscribe to our
monthly e-newsletter, SurfAdvisory at:
http://surfcontrol.us-hosts.com/sc/subscribe

****************************************************************************
The information in this email is confidential and may be legally privileged.
It is intended solely for the addressee. Access to this email by anyone else
is unauthorized. If you are not the intended recipient, any disclosure,
copying, distribution or any action taken or omitted to be taken in
reliance on it, is prohibited and may be unlawful. If you believe that you
have received this email in error, please contact the sender.
****************************************************************************

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Roland Glenn McIntosh 2003-06-13 15:15:22 SOLUTION: Insert a Euro symbol as UTF-8 from a latin1 charset.
Previous Message scott.marlowe 2003-06-13 15:04:50 Re: RE : PostgreSQL coredump : Couldn't find any tables,