dbatools is a free PowerShell module with over 200 SQL Server administration, best practice and migration commands included.

Please note that documentation and command names may be out of date while we work furiously towards 1.0


Get-DbaConfigValue

Returns the configuration value stored under the specified name. This command is usually only called by functions.

Screenshots

Examples

To return the configured value that was assigned to the key ‘path.dbatoolslogpath’

Get-DbaConfigValue -Name path.dbatoolslogpath

Returns the configured value for ‘Default.CoffeeMilk’. If no such value is configured, it returns ‘0’ instead.

Get-DbaConfigValue -Name ‘Default.CoffeeMilk’ -Fallback 0

Author

This command was created by Friedrich Weinmann. You can find Fred on blogging at allthingspowershell.blogspot.de and Tweeting at @FredWeinmann

Get-Help

From PowerShell, execute Get-Help Get-DbaConfigValue -Detailed for more information on this function.

Source Code

Want to see the source code? View Get-DbaConfigValue.ps1 on GitHub
 

Related commands