Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Producing an Update Log
Message
From
29/11/2014 08:05:16
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
 
To
28/11/2014 15:09:42
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Network:
Windows 2008 Server
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01609383
Message ID:
01611539
Views:
66
>>>>>The code works well EXCEPT that please look at the following code that generates all the OR conditions:
>>>>...
>>>>>I'm getting an error that the SQL statement is too long, probably because there are so many fields to process. How can I solve this?
>>>>
>>>>Split that after some number of fields and build three, four cursors (or as many as it takes), so that the field list for each one of them is short enough. Then select... union them into one, assuming you don't have any memos in there.
>>>
>>>That part is easy. Thanks. HOWEVER, this solution will leads to duplicate records if, say, fields #5 do not equal and ALSO fields #88 do not equal if the 2 fields are dealt with in different cursors.
>>
>>UNION will remove duplicate rows, UNION ALL will have the undesired effect you mention.
>Thanks! That worked.

Sorry I forgot to mention that bit... I've burned my fingers on the difference so many times that now for me it goes without saying.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform