sql script

Got a problem you cannot solve? Try here.
coder12345
Posts: 16
Joined: Sun May 07, 2006 8:04 pm

sql script

Postby coder12345 » Mon Aug 13, 2007 5:30 am

Hi,

I'm having trouble getting the sql script to create a non-existing database and then execute the script on it. I'm not exactly sure what the problem is, I am using the correct sa password. Any help would be greatly appreciated! Thanks!

Alex_Ronquillo
Site Admin
Posts: 364
Joined: Mon Jul 30, 2007 11:51 am
Location: USA
Contact:

Postby Alex_Ronquillo » Mon Aug 13, 2007 9:35 am

Please give more details about this. Are you getting some kind of error? Can you include the script you are using? What version of IA are you using? What OS are you using?
Alejandro Ronquillo
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/

coder12345
Posts: 16
Joined: Sun May 07, 2006 8:04 pm

sql script

Postby coder12345 » Wed Aug 15, 2007 6:54 am

I'm not getting any error messages, the database is just not being created and the sql script is not running.


IA7 WinXPSP2


****Updated****

Sorry, I thought I had attached this jpg. The problem that I'm having is that the database 'UserDatabase' is not being created.

File Attached:

untitled.JPG
Last edited by coder12345 on Wed Aug 15, 2007 7:17 am, edited 6 times in total.

neillans
Posts: 536
Joined: Sat Nov 04, 2006 6:21 am
Location: Scottish Borders, UK
Contact:

Postby neillans » Wed Aug 15, 2007 6:55 am

Can you post *exactly* the command you are using (and your script)?

One thing that people always seem to forget, is before you can create a database you need to OPEN an already existing database - the typical one is the default "master" :)
Andy Neillans

coder12345
Posts: 16
Joined: Sun May 07, 2006 8:04 pm

sql script

Postby coder12345 » Thu Aug 16, 2007 11:59 am

Sorry, I thought I had attached this jpg. The problem that I'm having is that the database 'UserDatabase' is not being created.

File Attached:

untitled.JPG

Alex_Ronquillo
Site Admin
Posts: 364
Joined: Mon Jul 30, 2007 11:51 am
Location: USA
Contact:

Postby Alex_Ronquillo » Thu Aug 16, 2007 12:45 pm

I am not sure if (local) works for local installation of MS SQL. Please try "localhost" instead and let me know the result
Alejandro Ronquillo

InstallAware

Home of The Next Generation MSI Installer

Get your free copy today - http://www.installaware.com/

Gizm0
Posts: 339
Joined: Wed Nov 09, 2005 8:47 pm

Postby Gizm0 » Thu Aug 16, 2007 12:57 pm

Alex_Ronquillo wrote:I am not sure if (local) works for local installation of MS SQL. Please try "localhost" instead and let me know the result


It works. The default for MS SQL IS (local) not localhost or anything like that. It's either IP or (local).

Now, to the question. You forgot to OPEN a new database as neilans told you above. Please insert this "USE [Biodb] GO" before setting the date format. It's even better to create the database from within a script than leaving IA to do it.
Panagiotis Kefalidis
Software Design Team Lead
\"In order to succeed, your desire for success should be greater than your fear of failure\"
InstallAware Software Corporation

coder12345
Posts: 16
Joined: Sun May 07, 2006 8:04 pm

sql script

Postby coder12345 » Thu Aug 16, 2007 4:10 pm

Hi,

Thanks for all the suggestions. =) I am still having some problems.

I tried "USE [Biodb] GO" and also "USE master GO" but the database 'UserDatabase' is still not being created.


Gizm0 wrote:It's even better to create the database from within a script than leaving IA to do it.


Where would be the a nice, reliable place to put this script? Should I do it within IA?
I kind of wanted to rely on IA to create this database for me since I'm not an SQL expert or anything. What are the pros and cons of relying on IA to do it for me vs. doing it myself?

Thanks!


Return to “Technical Support”

Who is online

Users browsing this forum: No registered users and 79 guests