Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Multiple patches and propery table changes


5 replies to this topic

stegmann

stegmann
  • Members
  • 4 posts

Posted 12 August 2003 - 18:06

We will be producing multiple independent small patches for our product. I am attempting to have each patch add a property table entry to the original database called "PatchName". This property does not exist in the original release. Each patch uses the same property to identify itself to a custom action.

I create the patches without error. When I apply patch 1, the PatchName property is added to the database as expected. When I apply patch 2 to a fresh install, the PatchName property is added to the database as exected. When I apply patch 1 followed by patch 2, the PatchName property stays at the value used in patch 1--it does NOT get update with the new value.

Why will additional patches not update the property added by another patch? Could this be because the property does not exist in the original database? There shouldn't be any restrictions on patches overwriting the same property, should there?

Thanks for any info,
Bob.


Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 12 August 2003 - 19:53

Maybe your patch1 gets re-applied? That depends on the version comparison settings you make. Create a log file to find out what's going on.

stegmann

stegmann
  • Members
  • 4 posts

Posted 12 August 2003 - 20:11

As I understand it, any patches don't actually update the cached msi, but rather they are reapplied anytime that you rerun the install (for another patch/maintenance mode). So if my understanding is right, it is running patch 1 again (from a cached msp), along with patch 2 (hopefully in that order). I've done verbose logging, but I must admit I find it rather hard to extract anything useful from it. It does appear to be applying the transform from patch 1 (again) and then the transform from patch 2, and indeed both sets of file changes do get installed, but I only can find a property table update in conjuction with the first patch--it doesn't appear again later in the log file, and of course the added property shows the value from the 1st patch.

As this is a small update, the version stays the same. I can't make one patch supersede another, because they are independent fixes. I can't make each patch "know about" all other other patches, because it's impossible to know about future fixes, and the patches should be able to be installed in any order.

I'm really up against a wall here. This would seem to be a serious deficiency in WI, and it also appears to be one that they are finally addressing in WI 3.0--when they add the ability to sequence patches. This seems to imply that there is no sequencing in the current implementation, which compromises the ability to change the database with multiple small update patches.


Stefan Krueger

Stefan Krueger

    InstallSite.org

  • Administrators
  • 13,269 posts

Posted 12 August 2003 - 20:22

Yes, your understanding is correct (or at least my understanding is the same). If you cannot change the ProductVersion then you cannot enforce a patch sequence nor can you lock out one patch.
What you could try (just an idea) is a custom action that would set the property. If both patches have such an action, but patch 2 has it later in the sequence, it should win. (Alternatively it could append to the existing property so you get a list of all installed patches)

stegmann

stegmann
  • Members
  • 4 posts

Posted 12 August 2003 - 20:48

Stefan,
Thanks for the reply and the idea: I couldn't set the property for each patch, as I can't depend on the order of patch installation by the customer, but appending to the property might just work. I suspect I'll have to add a CA for each patch, each with a difference sequence number, but in the end I can have a property which contains all applied patches, which is really what I want anyway. I'll report back success or failure.

Bob.

stegmann

stegmann
  • Members
  • 4 posts

Posted 15 August 2003 - 22:31

Well, looks like this method is going to work for me. Each patch adds a new type 51 custom action, setting PatchName = [PatchName]NameOfThisPatch, and each new CA is assigned a spot in the installexecute sequence. My original CA which looked for PatchName is also modified by the patches to handle the new format. Kinda kludgy, but it works. Thanks for the help.

Bob.