Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL: ORDER BY clause is invalid
Message
 
 
To
02/04/2005 04:10:10
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Network:
Novell 5.x
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01000629
Message ID:
01000996
Views:
58
>Sergey, the issue is very simple to understand,
>the VFP search ORDER by fieldName on tablesource before to search into the SELECT fields list,
>this is the BUG, they do not serve examples, enough to think;
>i try to show this to Aleksey, but without happening.
>
>However,A simple example is this:
>
>CREATE CURSOR test (aa m)
>SELECT DISTINCT LEFT(AA,1) AS AA FROM TEST ORDER BY 1
>
>SELECT DISTINCT .t. AS AA FROM TEST ORDER BY AA
>
>CREATE CURSOR test (aa m)
>SELECT DISTINCT LEFT(AA,1) AS AA FROM TEST ORDER BY 1
>* BUG
>SELECT DISTINCT LEFT(AA,1) AS AA FROM TEST ORDER BY AA
>* if previous has not convinced to you, then
>SELECT DISTINCT .T. AS AA FROM TEST ORDER BY AA
>* DISTINCT is insignificant
>SELECT LEFT(AA,1) AS AA FROM TEST ORDER BY AA
>* more simple
>SELECT .T. AS AA FROM TEST ORDER BY AA
>* if not enough, then not there is hope
>
>
Fabio,

Aleksey explained to you many times that it isn't a bug. A table field takes a precedence over field alias name. Period. I, personaly, don't like that rule either but it doesn't make it a bug. I don't see that there's anything left to discuss. You can submit a whish asking to change this behavior in the next VFP version.
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform