cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Jonathan
Level 4

How do I get rid of [DATABASEDIR]?

For some reason that I cannot fathom, ISX2011 has decided I need the [DATABASEDIR] which I am not using at all. It is set to the default value [INSTALLDIR]Database, but I am not using it. When I test my install I now get a subdirectory \Database with no files in it. I have the setting about not including subdirectories with no files but this still doesn't get rid of it. I don't use the [DATABASEDIR] and I cannot find any reason why Installshield feels it must create this directory.

Advice anyone?

Thanks
Jonathan

PS I have built 2 complete installs for sister products and the other install does NOT do this. I can see in the msi the directory is to be created but I want to eliminate it from the ise (InstallShield) project rather than have to tweak the msi all the time.
Labels (1)
0 Kudos
(8) Replies
hidenori
Level 17

You can open your .ise project file in Orca.exe and delete the entry that creates the [DATABASEDIR] directory.

Hope that helps.
0 Kudos
Jonathan
Level 4

Hi Hidenori,

I tried this before I posted but wasn't convinced I wouldn't just corrupt the database altogether.

I renamed the file extension from ise to msi & opened in ORCA.
Under CreateFolder I deleted two entries which listed Databasedir (for my install these were ISX_DEFAULTCOMPONENT7 & ISX_DEFAULTCOMPONENT48 in my install)
I saved from ORCA and renamed the extension from msi to ise & opened in ISX2011.
I then rebuilt the install.

Testing the install showed this was enough to get rid of the spurious \Database directory but still left me with questions as to what I was doing and why it was ever there.
Should I also delete the ISX_DEFAULTCOMPONENT7 & ISX_DEFAULTCOMPONENT48 from the Component table when editing the ise in ORCA?
If I do that, how do I know what these component are and whether I've not broken some other part of my install.

Besides all this - the bigger questions are
- why has ISX done this? (I never use the [DATABASEDIR])
- why can't I find this entry using the ISX GUI and remove it (rather than resort to ORCA)?
- why hasn't the remove unused directories stopped this directory being created?

Thank you for you time
Jonathan
0 Kudos
Jonathan
Level 4

Some additional information.

Running the ICE tests on the MSI package resulting from the above edits to the ISE & rebuilding the install in ISX2011 I found there were a number of ICE18 errors, teo of which related to this problem (I never understand why the others get there, but that is another issue!).

KeyPath for Component: 'ISX_DEFAULTCOMPONENT7' is Directory: 'DATABASEDIR'. The Directory/Component pair must be listed in the CreateFolders table.

and

KeyPath for Component: 'ISX_DEFAULTCOMPONENT48' is Directory: 'DATABASEDIR'. The Directory/Component pair must be listed in the CreateFolders table.

I assume that my earlier post about needing to do more was correct. I'm not that used to editing with ORCA and I'm not sure what is safe to delete and what is linked to other parts of the information.

So if I go back tot he ISE and delete these two components from the Component table using ORCA, then rebuild from that edited ISE using ISX2011, will this be enough?

What are these two components? Where can I find them listed from within the ISX2011 GUI? How do I find out what else they are doing?

Thanks
Jonathan
0 Kudos
hidenori
Level 17

My assumption is that you had a file under the DATABASEDIR folder one-time. InstallShield creates a component for the file internally, but it does not delete the component automatically when the file is removed from the folder because it is potentially shared by other resources such as INI file changes. For now you need to delete the components and CreateFolder entries manually using Orca. The Express edition does not provide the UI that allows you access to components.
0 Kudos
Jonathan
Level 4

Well its useful to know that these components can be created and left in there. ISX could do with being more intelligent, or have a clean-up tool to find orphaned items and offer to delete them. I take it from what you are saying that if I add a file under a feature it may create a component for the feature. If I then remove the file (even if I add it to another feature) I could have this component left in the ISE database, and it then gets carried through to the MSI/install.

Why didn't the "Keep Unused Directories" = No work in this case?

For the record, and should anyone else find this thread useful, here is what I did to remove these errors from my install project. I am not an expert (which is why we use the Express edition).

Rename the ise extension to msi. Edit with ORCA
Find and delete ISX_DEFAULTCOMPONENT48 entries
Fo me they appeared in the following tables
Component table
CreateFolder table
FeatureComponents
ISComponentExtended

Repeat the above for ISX_DEFAULTCOMPONENT7

Note that FeatureComponents table tells you which feature it is linked with, so its worth checking that feature to see what else is being done for it.

Rename msi to ise and rebuild the install in ISX
Test the resulting (real) MSI using ORCA
ICE errors associated with this problem are now gone

However, for me there were still 4 ICE18 errors eg

KeyPath for Component: 'ISX_DEFAULTCOMPONENT10' is Directory: 'WindowsFolder'. The Directory/Component pair must be listed in the CreateFolders table.

Two of these were from something orphaned like the earlier issues so I deleted them in a similar fashion.

The final two were more interesting. The ORCA validation claimed entries needed to be added to the CreateFolders table. I checked all references to these components and by way of a check I compared them to another component that was not being flagged with any ICE errors. I found all three components were effetively the same - all had similar entries with only the GUIDs and the dynamic file linking being different. I could see no reason why two were being flagged and the third not. Very strange and not really what you want from a validation test. I added two entries to the CreateFolders table and the errors went away - but I still don't see why the other component doesn't cause the same error.

Thanks
Jonathan
0 Kudos
hidenori
Level 17

If a directory that is listed in the Directory column of the Directory table is not referenced in any known location in the .msi file, InstallShield removes it from the Directory table of the .msi file that it creates at build time when the Keep Unused Directories setting is set to No. Therefore, the DATABASEDIR directory entry is not cleaned up because it is referenced by the Component and CreateFolder tables.

Also, I filed the enhancement work order IOA-000059974 for the clean-up issue so that we will take into consideration for a future release. For more information about ICE 18, please check out this MSDN help topic.
0 Kudos
Jonathan
Level 4

Hi Hidenori,

I just posted a reply and it disappeared, so if two turn up now I can only apologise.

Thanks for the insight into the unused directories in ISX. Also thanks for putting forward the suggestion about a clean-up for a possible future enhancement. I never use the upgrade between versions of ISX because of the many problems that seem to occur, I always start the install project from scratch. Thinking back, I can imagine that some of these issues may have been related to this problem.

I have been using the Microsoft help pages for the ICE errors. I wonder if you (or anyone) can suggest a good overview book or web page for MSI and ORCA? Building the installs is only a small part of my work and I could do with investing a bit more time in some of the background rather than picking it up bit-by-bit.

Thanks
Jonathan
0 Kudos
Esspweb
Level 2

Jonathan is absolutely right.
0 Kudos