× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



so I have a bill of material query (parent, child) joining to a item
master file (twice, once on parent, once on child) and a status file(
joined on parent)... I want the list ordered by parent...

select parent,child,t02.desc,t03.desc,osipo# from
plan_bill t01
join items t02 on t02.item = t01.parent
join items t03 on t03.item = chlid
join ordstatus t04 on ositm# = t01.parent
where
parent like '%MTG%' and
child like 'S%' and
osid = 'OS'
order by bprod ;

I have built all advised indexes, and when I run it takes 30 minutes to
return 800 records.
however, when I take off the order by, it runs in 2 seconds.
then, I tried: (parens around select statement)

(select parent,child,t02.desc,t03.desc,osipo# from
plan_bill t01
join items t02 on t02.item = t01.parent
join items t03 on t03.item = chlid
join ordstatus t04 on ositm# = t01.parent
where
parent like '%MTG%' and
child like 'S%' and
osid = 'OS' )
order by bprod ;

and that ran in 2 seconds...

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.