Problem statement: Few files in the application is getting changed and needs to be upgraded in the production environment.
1) One of the traditional solution is to re-create the full MSI for the changed files. It will works perfectly ok but it has many drawback. they are as follows:
- One has to first take the backup of the existing installed folder to save the configurations files.
- Then the existing installed application has to be un-installed from add/remove program.
- Finally, the new MSI has to be installed and the config files has to be re-stored.
All the above steps has to be done and forgetting a single step might bring down the production. In addition, all the above steps are manual steps and time consuming. We need a way that should just replace the file/s, those are updated by the developers. How? Here is the second solution.
2) Second solution is to create the quick Patch using Installshield 2014.
Here are the steps to create it:
- Launch InstallShield 2014.
- Select File – > New and then select “QuickPatch Project” as shown: Click Ok
- New QuickPatch Project screen will appear. Click Next.
- Select the Radio button “Based on an MSI Package” and click Next.
- Browse to the base MSI for which patch is to be created and click Finish.
- It will open the MSI database in the Installshield Interface. Select the files or registry or whatever needs to be updated. Let’s say files needs to be updated. Select Files from the Patch settings tree.
- From the right hand windows, either select the file/s from Original setup files tree and drag to the Files to patch tree Or right click on Files to Patch and select “Patch the existing file” open. This option will bring-up the screen with the list of files and can be selected as shown:
- Select the file and from updated file section, browse the updated file:
- Note the original version and the new version. Both versions should be different. If the content of files are different but the versions are same, installshield will treat them as same file and so, will not replace it. For the files where version number can not be changed, select the checkbox for overwrite any existing file.
- After all the files/registries are updated, select the General Information node and “Build settings” node. On the right hand window, from common node, unselect “Create Update.exe”. Do other changes from different tabs as per the requirements. Once done build the patch by clicking F7. It should be build successfully without any error.
- Go to Tools > Open Release Folder. “MSP” file will be seen on the release folder. Right click it and set the application information on the Details tab.
- To deploy the MSP, run the below command: msiexec /p [location/][Application].msp /qb+
Note: MSP has to be installed on the top of the existing base application. If the base application is not installed, it will throw the below error.