select Company as CustName, PcName as Contact, ; JobDescrip as JobName, ; padr(substr(JobDescrip,rat(" ",alltrim(JobDescrip))+1),30) as LastName, ; iif(JobType='SEXTW','1ELW','2ELM') as JobType, ; 'Active ' as JobStatus, Jobs.CurState as State, Jobs.JobID, Jobs.CustID ; from JobControl!Jobs inner join JobControl!Customer ; on Jobs.CustID = Customer.CustID ; where inlist(Jobs.JobType,'SEXTW','SEXTM') ; order by 5, 1, 2,4 ; into cursor ELM_ELW_JobsHowever, it produces incorrect result, e.g. job descriptions don't match their customers. Do you see anything wrong in this SQL (CustID is an Integer field and it's unique in Customer table)? Does it mean, what we have indexes' corruption?