Get-DbaKbUpdate
View SourceSynopsis
Retrieves detailed metadata and download links for Microsoft KB updates from the update catalog
Description
Searches Microsoft’s update catalog website to retrieve comprehensive information about KB updates including service packs, hotfixes, and cumulative updates. Returns detailed metadata such as supported products, architecture, language, file size, supersession information, and direct download links. Integrates with Get-DbaBuild to provide SQL Server-specific versioning details when available, making it essential for patch management and update research workflows. Note that parsing multiple web pages can be slow since Microsoft doesn’t provide an API for this data.
Syntax
Get-DbaKbUpdate
[-Name] <String[]>
[-Simple]
[[-Language] <String>]
[-EnableException]
[<CommonParameters>]
Examples
Example: 1
PS C:\> Get-DbaKbUpdate -Name KB4057119
Gets detailed information about KB4057119. This works for SQL Server or any other KB.
Example: 2
PS C:\> Get-DbaKbUpdate -Name KB4057119, 4057114
Gets detailed information about KB4057119 and KB4057114. This works for SQL Server or any other KB.
Example: 3
PS C:\> Get-DbaKbUpdate -Name KB4057119, 4057114 -Simple
A lil faster. Returns, at the very least: Title, Architecture, Language, Hotfix, UpdateId and Link
Example: 4
PS C:\> Get-DbaKbUpdate -Name KB4057119 -Language ja
Gets detailed information about KB4057119 in Japanese. This works for SQL Server or any other KB.
(Link property includes the links for Japanese version of SQL Server if the KB was Service Pack)
Example: 5
PS C:\> Get-DbaKbUpdate -Name KB4057119 -Language ja | Save-DbaKbUpdate
Downloads Japanese version of KB4057119.
Required Parameters
-Name
Specifies the KB article number to search for, with or without the ‘KB’ prefix. Accepts multiple values for batch processing.
Use this to retrieve update information for specific knowledge base articles like security patches, cumulative updates, or service packs.
| Property | Value |
|---|---|
| Alias | |
| Required | True |
| Pipeline | false |
| Default Value |
Optional Parameters
-Simple
Returns only essential update information to improve performance by skipping detailed web scraping. Provides Title, Architecture, Language, Hotfix status, UpdateId, and download Link.
Use this when you need basic KB information quickly or when processing many updates where full details aren’t required.
| Property | Value |
|---|---|
| Alias | |
| Required | False |
| Pipeline | false |
| Default Value | False |
-Language
Filters results to show only updates for a specific language when multiple language versions exist. Service Packs typically have separate files per language, while Cumulative Updates usually include
all languages in one file.
Use this when you need updates for non-English environments or want to download language-specific packages. Accepts standard language codes like “en” for English, “de” for German, or “ja” for
Japanese.
| Property | Value |
|---|---|
| Alias | |
| Required | False |
| Pipeline | false |
| Default Value |
-EnableException
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.
| Property | Value |
|---|---|
| Alias | |
| Required | False |
| Pipeline | false |
| Default Value | False |
Outputs
PSCustomObject
Returns one object per KB update link found in the Microsoft update catalog. The properties returned depend on whether the -Simple switch is used and whether build version information is available from Get-DbaBuild.
Default display properties (full detailed output, when -Simple is NOT used):
- Title: The name/title of the KB update (e.g., “Cumulative Update 23 for SQL Server 2019”)
- NameLevel: SQL Server release name (SQL Server 2019, 2017, etc.) from Get-DbaBuild
- SPLevel: Service Pack level (SP0, SP1, etc.) from Get-DbaBuild
- KBLevel: KB article number from Get-DbaBuild
- CULevel: Cumulative Update number from Get-DbaBuild
- BuildLevel: Full build number from Get-DbaBuild
- SupportedUntil: Support end date from Get-DbaBuild
- Architecture: CPU architecture - “x64”, “x86”, or “ARM64” based on extracted architecture information
- Language: Language identifier for the KB update (e.g., “en-US” for English)
- Hotfix: Boolean or status indicating if this is a hotfix (True/False)
- Description: Full description of the KB update contents and fixes
- LastModified: DateTime when the KB update was last modified
- Size: File size of the download package
- Classification: Microsoft classification (Critical, Important, Security Update, etc.)
- SupportedProducts: Array of supported SQL Server versions/editions
- MSRCNumber: Microsoft Security Response Center bulletin number if applicable
- MSRCSeverity: MSRC severity rating (Critical, Important, Moderate, Low)
- RebootBehavior: Whether installation requires reboot (Yes, No, Can be deferred)
- RequestsUserInput: Whether installation requires user input (Yes, No)
- ExclusiveInstall: Whether this update is exclusive/incompatible with other updates (Yes, No)
- NetworkRequired: Whether network connectivity is required during installation (Yes, No)
- UninstallNotes: Notes about uninstalling this update
- UninstallSteps: Steps required to uninstall this update
- UpdateId: Internal Microsoft update catalog GUID
- Supersedes: Array of KB articles superseded by this update
- SupersededBy: Array of KB articles that supersede this update
- Link: Direct HTTP/HTTPS download URL from download.windowsupdate.com
When -Simple switch is specified (reduced property set for performance):
- Title: The name/title of the KB update
- Architecture: CPU architecture (x64, x86, etc.)
- Language: Language identifier
- Hotfix: Boolean indicating if this is a hotfix
- UpdateId: Internal Microsoft update catalog GUID
- Link: Direct download URL
When build information is unavailable from Get-DbaBuild:
The following properties are excluded: NameLevel, SPLevel, KBLevel, CULevel, BuildLevel, SupportedUntil Note: The function returns one object per download link found. A single KB article may have multiple links if different architectures or languages are available.
dbatools