This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- SQL Scripts view
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Sep 14, 2010
06:41 PM
SQL Scripts view
thanks to the help in this board, I was able to customize the SQLServerSelectLogin2 dialog and add a browse button where the user can choose a directory path for the database location.
Now, I have just realized that there is not a way to specify the database location in the SQL Scripts views of Installshield.
can anyone point me to how I can customize the location of the database when Installshield creates it (i.e. the "Create Catalog if Absent" checkbox is checked.)
Thanks!
Now, I have just realized that there is not a way to specify the database location in the SQL Scripts views of Installshield.
can anyone point me to how I can customize the location of the database when Installshield creates it (i.e. the "Create Catalog if Absent" checkbox is checked.)
Thanks!
(5) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Sep 17, 2010
10:44 AM
You need to uncheck the "Create Catalog if Absent" checkbox, and add a script that will create a database catalog using the CREATE DATABASE statement. The script may need to be scheduled to run at login.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Sep 21, 2010
06:41 PM
hidenori wrote:
You need to uncheck the "Create Catalog if Absent" checkbox, and add a script that will create a database catalog using the CREATE DATABASE statement. The script may need to be scheduled to run at login.
Thanks, hidenori, once again.
I had come to this conclusion but was hoping for another way - I had seen reference to Installshield Express making use of the [DATABASEDIR] property. I see this in the string editor - Identifier IDS__DatabaseFolder_DatabaseDir using [DATABASEDIR] as avalue. Is this not used at all in Installshield Pro?
Thanks!
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Sep 22, 2010
10:20 AM
[DATABASEDIR] is available in InstallShield Pro. In order to use the property in your SQL script, you need to use the Text Replacement functionality available in the SQL Scripts view. The following is a sample Text Replacement entry that will replace %DatabaseDir% with the value of the DATABASEDIR property in a SQL script:
Find What: %DatabaseDir%
Replace With: [DATABASEDIR]
and you need to change your SQL script like this:
Hope that helps.
Find What: %DatabaseDir%
Replace With: [DATABASEDIR]
and you need to change your SQL script like this:
CREATE DATABASE Sales
ON
( NAME = Sales_dat,
FILENAME = '%DatabaseDir%saledat.mdf',
SIZE = 10,
MAXSIZE = 50,
FILEGROWTH = 5 )
LOG ON
( NAME = Sales_log,
FILENAME = '%DatabaseDir%salelog.ldf',
SIZE = 5MB,
MAXSIZE = 25MB,
FILEGROWTH = 5MB ) ;
GO
Hope that helps.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 18, 2011
12:44 AM
I import script file at sql scripts view.
First time I run install scripts , it's doesn't work.
But I run next time,it's run.
Why sql scripts file doesn't work at first time.
Please help me!
First time I run install scripts , it's doesn't work.
But I run next time,it's run.
Why sql scripts file doesn't work at first time.
Please help me!
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 18, 2011
10:50 AM
zawmintun,
Do you receive any SQL scripting error at the initial install? What project type are you using?
Do you receive any SQL scripting error at the initial install? What project type are you using?
![](/skins/images/D60DF682EA37BF37032955CE10F3F0BB/responsive_peak/images/icon_anonymous_message.png)