Changes between Version 26 and Version 27 of DeveloperGuidelines/Optimisation
- Timestamp:
- 06/18/10 08:02:14 (15 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
DeveloperGuidelines/Optimisation
v26 v27 52 52 }}} 53 53 54 2. '''Ask exactly for what you expect''': 54 2. '''Ask exactly for what you expect''' (=limit your query): 55 55 56 - if you expect only one result, then limit the search by limitby: 56 57 … … 77 78 }}} 78 79 79 3. '''Don't ask twice for the same record''' :80 3. '''Don't ask twice for the same record'''. Look down your code whether your need the same record later on again: 80 81 81 82 {{{ … … 94 95 }}} 95 96 96 4. '''Don't loop over queries''', if you can avoid id :97 4. '''Don't loop over queries''', if you can avoid id. Sometimes it is not as easy to see as in the following example: 97 98 98 99 {{{