Upgrades

Applications get updated to correct various problems, change certain configurations or improve functionality.

For MSI packages, this can be done through patches and upgrades.

According to the Windows Installer Software Development Kit (SDK), there are three ways to update applications that are based on the Windows Installer technology, namely:

  1. Patching,
  2. Minor upgrades
  3. Major upgrades.

Patching (using msps) is like installing an add-on to an already installed application to update.

Upgrading (also referred to as a small update or minor update) is the process of re-installing a new improved version of an MSI, over an already installed version of the MSI.

Major upgrades are represented by improved versions of the package installed normally (they also take into account the uninstallation of older versions already installed on the machine).

Setting up Upgrades is super simple with Advanced Installer.

Patching

A patch (.msp) is a file used to improve an MSI (if you can look at it like this). Unlike an MSI, a patch contains only the information needed to update an installed version of an application. It includes either an entire file (or more) or just bits of it to update a file(s).

Check out the Creating Patches article on our Advanced Installer User guide.

One of the advantages of patches is that they can be uninstalled, bringing the application back to its initial stage. This way you avoid having to uninstall and reinstall the application (a feature available in Windows Installer 3.0 and higher versions).

To uninstall a patch and revert the application back to its initial stage, use the following command line:

Msiexec /package {GUID_OF_PRODUCT} /uninstall {GUID_OF_PATCH} /qb

Where:

  • {GUID_OF_PRODUCT} is the Product Code of the main MSI
  • {GUID_OF_PATCH} is the Revision number field in the msp file Properties, Details tab.
Patch Revision Number
Patch Revision Number

By using a utility (such as Advanced Installer or other), you can create a patch from two different MSIs:

  • one MSI containing the old versions of the files
  • another MSI created by us (based on the old one) to replace the old files with the new ones

A more in-depth article regarding Windows Installer patches can be found here.

Upgrading

Upgrading can be classified as follows:

Type of

update

Productcode

ProductVersion

Description

Small Update

No change

No change

An update to one or two files that is too small to warrant changing the ProductVersion.

The package code in the Revision Number.

Summary Property changes. It can be shipped as a full installation package or as a patch package.

Minor Upgrade

No change

Changed

A small update that makes significant enough changes to alter the ProductVersion property. It can be shipped as a full installation package or as a patch package.

Major Upgrades

Changed

Changed

A comprehensive update of the product needing a change in the ProductCode property. It is shipped as a patch package or as a full product installation package.

Applying a small update

A small update can be applied to an application either by fully reinstalling the application or only partially by using the command line.

Fully:

msiexec / fvomus [path to updated .msi file] or msiexec / I [path to updated msi file] REINSTALL = ALL REINSTALLMODE = vomus

Partially:

You need to find out which features and components are modified by this small update.

msiexec / I [path to updated .msi file] REINSTALL = [Feature list] REINSTALLMODE = vomus

Applying a major upgrade

A major upgrade involves installing the improved package. Major upgrades have a different product code than the original package and they must be treated as a new product, so it installs like any other package.

msiexec / i [path to updated msi file]