PRB: SQL AS Clause Is Ignored in UNION ALL StatementLast reviewed: June 27, 1995Article ID: Q109301 |
The information in this article applies to:
SYMPTOMSThe AS clause associated with the second SELECT statement in a UNION ALL statement is ignored. However, the AS clause associated with the first SELECT statement can be used to specify the desired column header; the AS clause also works as expected in a UNION statement.
RESOLUTIONFor a demonstration of how to work around this behavior, see "Workaround" in the "More Information" section below.
MORE INFORMATION
Steps to Reproduce Behavior
WorkaroundThe following code works around the problem:
SELECT customer.cno, invoices.ino AS B ; FROM customer, invoices; WHERE invoices.cno = customer.cno ; UNION ALL ; SELECT customer.cno, invoices.ino ; FROM customer, invoices ; INTO CURSOR new |
Additional reference words: FoxWin FoxDos 2.50 2.50a 2.50b alias ignore
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |