[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

SQR3 vs SQR2 problem.



I need to find out if any one is having this problem. We just upgraded SQR3.05 from SQR2.4.5. Here is the problem:

BEGIN-PROCEDURE sel-deductions
BEGIN-SELECT
pdrbded_bdca_code (,) on-break print=never before=report-heading after=next-page
spriden_id (+1,1)
spriden_last_name (,13)
pdrbded_begin_date (,35)
pdrbded_end_date (,46)
pdrbded_bdca_code &ded_code
ptrbdca_long_desc &ded_description

From......

ORDER BY pdrbded_bdca_code,spriden_last_name,spriden_id
END-SELECT
END-PROCEDURE

The above query works well with SQR2.4.5 BUT NOT with SQR3.05. Here is the error message when run with SQR3.05:

(SQR 5528) ORACLE OPARSE error -960 in cursor 12:
ORA-00960: ambiguous column naming in select list
SQL: select pdrbded_bdca_code, spriden_id, ....
Error at: pdrbded_bdca_code

Error on line 296:
(SQR 3716) Error in SQL statement.

Errors were found in the program file.
SQR: Program Aborting.

If you've noticed, the select clause has two same fields (pdrbded_bdca_code). And 'ORDER BY' by that field. This works fine under SQR2 but not SQR3.05. If I remove one of these fields from select clause then SQR3.05 runs OK. Or if I remove that field in 'ORDER BY' and leave these two fields in select clause then SQR3.05 runs OK too. Either cases, I don't want to remove any thing.
I would appreciate for any clue about this. Thanks.

Ben.



------------------------------------------------------------------------
Benjamin Le Phone: (503)-977-4970
Portland Community College Fax: (503)-977-4987
ITS, System Development E-mail: ble@pcc.edu
PO Box 19000 Portland, OR. 97280-0990 U.S.A. Web: http://www.pcc.edu
----------------------------------------------------------------------
--