We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

perezrule
Posts: 3
Joined: Mon Apr 27, 2015 6:33 pm

Detect previous version when updating

Hi I will like you help or advise on how to make and update installer that can detects what previouse version I have installed. So I can know how to run my sql scripts correctly to update the database. For example. if version installed is 1.0.2 and I will update to 1.0.4 I will need to run script to update database to version 1.0.4. Also if no previous version is installed I will need to run the full sql script.
Irina
Posts: 113
Joined: Mon Apr 27, 2015 11:42 am

Re: Detect previous version when updating

Hello and welcome to Advanced Installer forums!

In order to make this kind of update installer, you will have to start with an Enterprise project.

The Advanced Installer tool creates a registry key named Version, which you can see in the Registry page.
In order to make the conditional update you need, you will have to set up a registry search in Advanced Installer, using the Version registry.
This action will have as result the setting of a property (the RESULT_PROPERTY).

Next, you will have to create an SQL connection and add your scripts. The steps are described here.
For each script, you can add in the Condition field the RESULT_PROPERTY you created.

Do not hesitate to ask further questions.

Kind regards,
Irina
Ecaterina Irina Grosu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”