Author | Chrissy LeMaire (@cl), netnerds.net |
Availability | Windows, Linux, macOS |
Want to see the source code for this command? Check out Read-DbaAuditFile on GitHub.
Want to see the Bill Of Health for this command? Check out Read-DbaAuditFile.
Read Audit details from *.sqlaudit files.
Read Audit details from *.sqlaudit files.
Read-DbaAuditFile
[-Path] <Object[]>
[-Raw]
[-EnableException]
[<CommonParameters>]
PS C:\> Read-DbaAuditFile -Path C:\temp\logins.sqlaudit
Returns events from C:\temp\logins.sqlaudit.
PS C:\> Get-ChildItem C:\temp\audit\*.sqlaudit | Read-DbaAuditFile
Returns events from all .sqlaudit files in C:\temp\audit.
PS C:\> Get-DbaInstanceAudit -SqlInstance sql2014 -Audit LoginTracker | Read-DbaAuditFile
Reads remote Audit details by accessing the file over the admin UNC share.
The path to the *.sqlaudit file. This is relative to the computer executing the command. UNC paths are supported.
Alias | FullName |
Required | True |
Pipeline | true (ByValue) |
Default Value |
If this switch is enabled, the enumeration object will be returned.
Alias | |
Required | False |
Pipeline | false |
Default Value | False |
By default, when something goes wrong we try to catch it, interpret it and give you a friendly warning message.
This avoids overwhelming you with "sea of red" exceptions, but is inconvenient because it basically disables advanced scripting.
Using this switch turns this "nice by default" feature off and enables you to catch exceptions with your own try/catch.
Alias | |
Required | False |
Pipeline | false |
Default Value | False |