Need suggestion as due to performance improvement i need to convert all loop queries to IN clause. I have following where conditions which may vary based on iteration..
Where recordID=2323 and (origin=626 or destination=319);
Where recordID=2323 and (origin=319 or destination=789);
Where recordID=2323 and (origin=567 or destination=989);
Where recordID=2323 and (origin=767 or destination=626);
For performacne improvement i want to convert those queries to IN Clause like this..
Where recordID=2323 and (origin IN(626,319,567,767) or destination IN (319, 789, 989, 626));
My question is the results count from both approach will be the same? Is there any other approach or any other way to do this.
Problem is my final count is not samilar compare to each approach.