Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL Union with Order clause not working
Message
From
24/02/2004 15:42:43
 
 
To
24/02/2004 15:35:00
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00880442
Message ID:
00880455
Views:
25
I thought they were, turns out one table has a bunch of numerics and the other has a bunch of integers. Don't know how that happend... programmer error. The cRow fields are the same though. DO both STRUCTURES have to be EXACTLY the same, not just the field I want to 'Order' on?

Aloha,

James

>>I can't figure this one out...
>>
>>This command doesn't work:
>>
>>SELECT 'Sold' as Dataset,* from sold ;
>>       UNION select 'Mailed' as Dataset,* from mailed ;
>>       ORDER BY cRow INTO CURSOR temp
>>
>>
>>This command DOES work:
>>
>>SELECT 'Sold' as Dataset,* from sold ORDER BY cRow INTO CURSOR temp
>>

>
>Besides what Gunnar told you about the order column, consider that Union works if both table columns (fields) being returned are the same. You used * in both. Are the two file structures the same?
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform