You didn't say how many rows are in these tables. 

Go xBase. Try COPY TO and APPEND FROM.

--
rk

-----Original Message-----
From: [email protected] [mailto:[email protected]] On 
Behalf Of MB Software Solutions General Account
Sent: Thursday, August 16, 2012 10:29 AM
To: [email protected]
Subject: Query taking 4 minutes...ugh

VFP9SP2 - WinXP - dbfs on network

I have to query 2 tables to populate a lookup list:

SELECT x1.provnum ;
FROM (ADDBS(this.cDataPath)+this.cClaimsTable) x1 ; UNION ; SELECT x2.provnum ; 
FROM (ADDBS(this.cDataPath)+this.cDischargeTable) x2 ; INTO CURSOR curTemp

This query is taking forever (4 minutes!).  There's no WHERE clause so it's not 
optimizable.  But is there a better way?

My current plan now is to create logic that extracts the provnums into a 
separate table and just query that.  That makes complete sense to me. 
(These tables are basically input files from a vendor, with the provnum built 
in and not sent in a separate lookup table.)

Other ideas?

tia,
--Mike


_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/profox
OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: 
http://leafe.com/archives/byMID/profox/DF1EEF11E586A64FB54A97F22A8BD044216907E295@ACKBWDDQH1.artfact.local
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to