Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
BUG: SELECT UNION bad fieldname with a order pass
Message
From
05/09/2005 18:19:10
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01046830
Message ID:
01046861
Views:
17
>>>It's documented behavior of ORDER BY in UNION query in VFP9.
>>>
>>
>>where ?
>
>VFP9 help SELECT - SQL Command - ORDER BY Clause
>
>"If the ORDER BY clause is applied to a UNION operation, the alias should be a Select_Item in the last SELECT clause".

And this what it centers with the name of the fields of the result?

I hope that Aleksey he realizes where the error is
(it is in an array of names of the internal routine C++)

Do you think that it is correct that these two queries return two different results?
CREATE CURSOR AA (MM I)

SELECT 1.00 X1 FROM AA;
UNION ALL;
SELECT 1.00 FROM AA ORDER BY 1

SELECT 1.00 X1 FROM AA;
UNION ALL;
SELECT 1.00 Y1 FROM AA ORDER BY 1
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform