Re: data design optimization
You just want rows where ActivityID = 0 and PeriodStart < _PeriodEnd and PeriodEnd > _PeriodStart? Why not just ...
)
SELECT * FROM BudgetActivities
WHERE WHERE ActivityID = 0
AND PeriodStart < _PeriodEnd
AND PeriodEnd > _PeriodStart
ORDER BY ActivityGroupID,ActivityID;
If that's still slow, try adding indexes on activitygroupid and on periodstart, periodend.
PB
Subject
Views
Written By
Posted
2795
March 30, 2006 07:44AM
1823
March 30, 2006 09:02AM
1990
March 30, 2006 01:41PM
2425
March 30, 2006 01:43PM
Re: data design optimization
1927
March 30, 2006 04:03PM
1926
March 31, 2006 01:42PM
1793
March 31, 2006 04:59PM
2064
April 01, 2006 06:38AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.