I have the following sql statement that takes about 2.5 minutes to
give me my data. The time it takes is an issue because this sql
statement is used in my intranet asp page. But it even takes 2.5
minutes in sql plus.
SELECT stuHunterNum, stuBowNum, pplDOB, pplLName, pplFName,
pplMName,zipCity, pplZip FROM mdhunted.tblPeople,
mdhunted.tblStudents, mdhunted.zipcode
WHERE tblpeople.pplid(+) = tblstudents.pplid AND pplzip = zipzip(+)
AND
pplUlname LIKE upper('Smith%') order by tblpeople.pplLName,
tblpeople.pplFName, tblpeople.pplMName
tblPeople has about 550,000 records and is indexed by pplid, lname,
fname, and mname.
tblStudents has also about 550,000 records and is indexed by pplid.
It acts like it is using the indexes in tblPeople but not in
tblStudents and therefore reading each record in tblStudents.