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

Installing Files Help Needed.


3 replies to this topic

posty

posty
  • Members
  • 58 posts

Posted 30 April 2002 - 19:48

I need to install scripts and batch files depending on what database the user will connect to.  The three databases are Oracle, MSSQL and DB2.

Now, the batch files must go into the [INSTALLDIR]\bin directory and the scripts to the [INSTALLDIR]\bin\sql directory.

Now here is the kicker.  The filenames are the same for each of the databases, but when I add one set (i.e. DB2) and then try to add one of the other two, it asks if I want to replace the existing file.  I don't want to replace, I want to add it to the same location for all operating systems but whatever the user selects for the DB, I will turn off the other two components and leave the other active.

Can this be done??  If not, I need to come up with some other way.

Thanks.

Dave I

Dave I
  • Members
  • 195 posts

Posted 01 May 2002 - 10:21

Not sure if I understand you correctly, but...

You could just created six components, OracleBatch, MSSQLBatch, DB2Batch, OracleScript, MSSQLScript, DB2Script.    And apply a condition to each of the components.

One way would be to use the Appsearch and Signature tables to locate a file unique to each database, you could then use the conditions ORACLEPRESENT, DB2BATCHPRESENT, etc.

Alternatively, add a dialog with radiobutton group and allow the user to select the database, this would give conditions on you components of OracleBatch, DATABASE="ORACLE". MSSQLBatch, DATABASE="MSSQL" for example.

Let me know if you want any help,
Dave

hteichert

hteichert
  • Members
  • 158 posts

Posted 02 May 2002 - 08:40

I know that you have 2 times (script/batch) 3 files where one of these 3 must be copied to 1 location, but i will only describe the case 1 out of 3 (the other is the same)

The problem is, that there are three files of the same name which shall be installed to the same location depending on a condition (DB2/Oracle/MSSQL). But these three files must be stored somewhere on the distribution media. To allow this, it's necessary to give ISWi/Developer a bit of extra information where to store these files on the media where you install from (CD for example).

You have to create 3 components, one for DB2, one for Oracle and one for MSSQL and these must be installed conditionally, depending on the selected/detected database.
They will all have the same destination directory but there must be info entered to the field "Source Location" (in ISWi 1.52). The files that you will put in this component will then be stored in a subfolder of this name on the distribution media.

There would be a structure like
...\script
     +---\Oracle\my.sql
     +---\DB2\my.sql
     +---\MSSQL\my.sql

on the distribution media and depending on the condition one of these my.sql's will be installed to ...\script on the destination machine.
h.teichert-ott

posty

posty
  • Members
  • 58 posts

Posted 04 May 2002 - 16:02

hteichert, that worked.

Thanks!

:D