As an example, an online shopping cart may audit searches by keyword and may audit individual product pages. At the database level the sql run to generate such pages can be marked with a comment and a textual description of the functionality of the application that uses such a query. This permits application level auditing to be performed in the database, and not require that the auditor is educated in the full set of statements that may be performed by the application. This method of auditing can be done in addition to application level auditing functionality.
Comments are also useful in the enterprise manager to look up statements that are candidates for automated sql tuning.
To add comments to the statement use the following syntax -
SELECT /* [text] */ .....
When the statements require the use of hints ensure the comments do not get in the way of the correct hint definition. Ensure the comments are of the form
{DELETE|INSERT|SELECT|UPDATE} /*+ hint [text] [hint [text]]... */
No comments:
Post a Comment