Discussion Locked
0 helpful
4 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.
I'm using Visual FoxPro 6.0 and I'm trying to create a query that would select records out of one table that are not in a second table and since I have very large tables I need it to be quick. I've been able to get the desired result but it's slow. I've not been able to find a true "comparison" for tables. Does anyone have any suggestions? Thanks, JMartin
4 replies
jmartin,
Are you doing this on a procedure or as a SQL Statement? With SQl you can use the Operator EXIST:
SELECT T1.PK
FROM T1
WHERE NOT EXIST (SELECT T1.PK WHERE T1.PK = T2.PK)
(Check that indexes exist for T1.PK and T2.PK)
It there any way you can reduce the number of records? For example if you do this every week, it may be posible to filter the changes by date?
Hope it helps,
JP
by jmartin
Thanks, got me started inright direction.
This discussion is closed to new replies.
Trending Web Development posts
Sort by Trending
0 helpful
5 replies
1 helpful
3 replies
0 helpful
1 reply
0 helpful
1 reply
Question Unanswered
PDF vs HTML
0 helpful
0 replies