Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Slow SQL Statement
Message
 
 
To
01/12/2005 21:55:48
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 6 SP5
OS:
Windows XP
Network:
Windows 2000 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01074021
Message ID:
01074025
Views:
17
Try
...
Where Not EXISTS (Select * From engpmtbl5a 
			Where badgeno = appusrprf1.badgeno
				AND tsstat = 1 And wend = whatWeek) 
...
>Each of the two parts of this SQL statement will complete in about 3 seconds. However, when I put them together it takes approox 60 seconds to run. Is there something to do that it would run faster?
>
>requiredListString = "Select appusrprf1.fname, appusrprf1.lname, appusrprf1.usrid1, appusrprf1.badgeno, appusrprf1.deptno, appusrprf1.emadd From appusrprf1 Where badgeno Not In (Select badgeno From engpmtbl5a Where tsstat = 1 And wend = '" + whatWeek + "') And times = 1 And activee = '" + PadR('Active',8) + "' Order By deptno, lname"
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform