Adds SQL statements to a transaction log for execution against the Microsoft® SQL ServerT database for the audit log. Used to modify the audit log for custom reporting purposes. Used by Microsoft Provisioning Framework (MPF).
The Audit procedure executes two kinds of statements:
Arguments | ||||||||||||||||||
The following table describes the XML elements and attributes. Unless otherwise indicated, the data type is string.
|
Remarks |
Audit does not create a database table at the same time it executes an INSERT command. The table must already exist in the audit log. SQL Provider contains a procedure, ExecSQL, that can also be used to execute commands against the audit log. However, be aware that the functionality is not identical. First, ExecSQL executes commands immediately, whereas Audit executes later. ExecSQL will also fail immediately if the audit log database is not available, but Audit will not, since it stores commands in a transaction log database until it is able to execute them. Note Audit is slightly simpler to use than ExecSQL because you do not have to specify database or server connection information in the request. MPF is already configured to locate the audit log database. To successfully execute Audit, the MPFServiceAccts user group requires access permissions for any tables and stored procedures referenced by the SQL commands. To grant these permissions, use SQL Enterprise Manager to assign MPFServiceAccts to the role MPFAuditRole for the database MPFAudit. To add tables and stored procedures to an existing audit log database, you must assign appropriate permissions to the MPFAuditRole in that database. Alternately, you can create a new audit log database. Audit acts only on data previously marked for auditing (for example, all successful transactions). It is entirely possible for the procedure to return successfully but not yield the desired results if the audit log does not contain the expected data. Audit levels for transactions and procedures are defined in Provisioning Manager; for more information, see Provisioning Engines. If Transactions marked for audit is selected, transactions that include calls to Audit are eligible. |
Schema Definition |
Input
|
Sample Code |
Example XML Request
The following code fragment shows the format for sending data to this procedure. For more information on individual elements and attributes, see the Elements and Attributes table.
Example XML Response
Audit does not return data. |
Applies To |
Custom Audit for:
|