Kbase P102498: SQL-92: Error (7523): Column ambiguously specified executing a SELECT statement.
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  26/03/2010 |
|
Status: Verified
SYMPTOM(s):
SQL-92: Error (7523): Column ambiguously specified executing a SELECT statement
Error(7523) executing a SELECT statement.
=== SQL Exception 1 ===
SQLState=HY000
ErrorCode=-20009
[JDBC Progress Driver]:Column ambiguously specified (7523)
Executing the SELECT statement:
SELECT
ShipDate,
Office,
"CARRIER-ID",
Airbill,
Vendor_airbill,
"Service-Level",
"Delivery-date"
FROM PUB.packages
INNER JOIN PUB.trace
ON
(ShipDate = PUB.trace.ShipDate) AND
("Internal-No" = PUB.trace."Internal-No")
WHERE
ShipDate = '03/18/2005' AND
Office = 'c';
SQL-92
FACT(s) (Environment):
All Supported Operating Systems
Progress 9.x
OpenEdge 10.x
CAUSE:
Some referenced fields have the same name in both tables of the query.
FIX:
Qualify the field names with the table names to remove the ambiguity:
SELECT
PUB.packages.ShipDate,
PUB.packages.Office,
PUB.packages."CARRIER-ID",
PUB.packages.Airbill,
PUB.packages. Vendor_airbill,
PUB.packages."Service-Level",
PUB.packages."Delivery-date"
FROM PUB.packages
INNER JOIN PUB.trace
ON
(PUB.packages.ShipDate = PUB.trace.ShipDate) AND
(PUB.packages."Internal-No" = PUB.trace."Internal-No")
WHERE
PUB.packages.ShipDate = '03/18/2005' AND
PUB.packages.Office = 'c';