Creating a database using IDbCommand

D

David Thielen

Hi;

If I want to run a script that creates a databse using
IDbCommand.ExecuteNonQuery - 2 questions:

1) What database do I connect to? I assume master.

2) How do I start the script? I think it's:

CREATE DATABASE [xxxAutoTag]
GO

USE [xxxAutoTag]
GO

SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
SET ANSI_PADDING ON
GO
CREATE TABLE [dbo].[Schedule](
....

thanks - dave

david@[email protected]
Windward Reports -- http://www.WindwardReports.com
me -- http://dave.thielen.com

Cubicle Wars - http://www.windwardreports.com/film.htm
 
D

David Thielen

The answer is yes & yes.

thanks - dave


Hi;

If I want to run a script that creates a databse using
IDbCommand.ExecuteNonQuery - 2 questions:

1) What database do I connect to? I assume master.

2) How do I start the script? I think it's:

CREATE DATABASE [xxxAutoTag]
GO

USE [xxxAutoTag]
GO

SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
SET ANSI_PADDING ON
GO
CREATE TABLE [dbo].[Schedule](
...

thanks - dave

david@[email protected]
Windward Reports -- http://www.WindwardReports.com
me -- http://dave.thielen.com

Cubicle Wars - http://www.windwardreports.com/film.htm


david@[email protected]
Windward Reports -- http://www.WindwardReports.com
me -- http://dave.thielen.com

Cubicle Wars - http://www.windwardreports.com/film.htm
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top