To continue with previous blog about SQL Optimization. How to do it better ,do need our effort on it for a long time. I just may provide some means to think about it. And I also want to exchange ideas with net friends.
Item 2:
WHERE clause order list should also have a rule: we should put the condition which can filter out maximum records to the last position.AS SQL interpreter first to deal with this condition. In Oracle internal sections there are many complicated operation when we end user who just do a simple SQL statement.
Item 3:
Please avoid using ‘*’ in SQL Statement. SQL interpreter meet across the symbol ‘*’ It will trigger to search related data dictionary. We know this process will also cost some time. Just to avoid using it when in convenience when we want to get one data set . please list out the columns instead of ‘*’.
Item 4:
To reduce database calls as many as possible. To avoid this ,we can think about oracle built-in function that when we create a process in oracle DB, we will use cursor to get data set . Why we do this thing like this, just to reduce DB calls. Its original principles are that: connection between one server is easier than connection between two or more servers( work stations).