General information
Category:
Coding, syntax & commands
I'm not an SQL expert, so forgive me if I misunderstand how this works, but can you order by a field that is not in the select clause? If not, then wouldn't it kind of mess up the whole purpose of the distinct to also select the PK field?
>You need to apply an ORDER BY clause to get the order you want from SQL, if you have a PK field, this USUALLY represents entry order.
>
>Bob
>
>>the command
>>
>>sele gtype distinct from vwxltbl into cursor vwxltblD
>>
>>sorts the field gtype, i wanted it to retain the original order, is that possible?
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only