I’m trying to create a setup file using InstallShield 2010 for my project which uses SQL Server 2008
Everything is ok all necessary programs are being installed but when I try to install my project it will give this error
Error 27506. Error executing SQL script dbName.sql Line 9
Create Database failed. some file names listed could not be created Check
related errors (1802)
I searched it says that my path in SQL script does not exist but how to make database to be created in installation folder of program itself?
Here first few lines of my SQL script
USE [master]
GO
/****** Object: Database [InventoryDB] Script Date: 08/11/2012 19:01:00 ******/
CREATE DATABASE [InventoryDB] ON PRIMARY
( NAME = N'InventoryDB', FILENAME = N'C:\Inventory\DB\InventoryDB.mdf' , SIZE = 2048KB , MAXSIZE = UNLIMITED, FILEGROWTH = 1024KB )
LOG ON
( NAME = N'InventoryDB_log', FILENAME = N'C:\Inventory\DB\InventoryDB_log.ldf' , SIZE = 2816KB , MAXSIZE = 2048GB , FILEGROWTH = 10%)
GO
ALTER DATABASE [InventoryDB] SET COMPATIBILITY_LEVEL = 100
GO
please help
I’m trying to create a setup file using InstallShield 2010 for my project which uses SQL Server 2008
Everything is ok all necessary programs are being installed but when I try to install my project it will give this error
Error 27506. Error executing SQL script dbName.sql Line 9
Create Database failed. some file names listed could not be created Check
related errors (1802)
I searched it says that my path in SQL script does not exist but how to make database to be created in installation folder of program itself?
Here first few lines of my SQL script
USE [master]
GO
/****** Object: Database [InventoryDB] Script Date: 08/11/2012 19:01:00 ******/
CREATE DATABASE [InventoryDB] ON PRIMARY
( NAME = N'InventoryDB', FILENAME = N'C:\Inventory\DB\InventoryDB.mdf' , SIZE = 2048KB , MAXSIZE = UNLIMITED, FILEGROWTH = 1024KB )
LOG ON
( NAME = N'InventoryDB_log', FILENAME = N'C:\Inventory\DB\InventoryDB_log.ldf' , SIZE = 2816KB , MAXSIZE = 2048GB , FILEGROWTH = 10%)
GO
ALTER DATABASE [InventoryDB] SET COMPATIBILITY_LEVEL = 100
GO
please help
- Remove From My Forums
-
Question
-
Again my question:
Hi good afternoon, I got this error when
installing a aplicaion and create a
database appears to me as follows:— Error 27506. Failed to execute
SQL script NewScript1.
Line 21. Incorrect syntax near ‘CONTAINMENT‘.
(102)Would I could help please?
What can or should I do to fix it?
Thanks
Best Regards
Horacio
-
Edited by
Tuesday, June 3, 2014 8:06 PM
-
Edited by
Answers
-
Hi hemaak,
According to your description, when you install an application and create a database, the error will occur. We need to verify if the error is happened when you create a database in SQL Server Management Studio.
If not, please post more detail for analysis. In addition, I recommend you post your SQL script. There is detail about how to create database and files used to store the database, you can review the following article.http://msdn.microsoft.com/en-us/library/ms176061.aspx
The containment parameter
specifies the containment status of the database, it applies to SQL Server 2012 , SQL Server 2014. If you use CONTAINMENT = NONE in your script statement, it is the default so you do not need it in statement. For more information, see:http://stackoverflow.com/questions/15408854/containment-is-marked-as-incorrect-syntax-on-auto-generated-database-script
Regards,
Sofiya Li
Sofiya Li
TechNet Community Support-
Marked as answer by
Sofiya Li
Wednesday, June 11, 2014 6:08 AM
-
Marked as answer by
- Remove From My Forums
-
Question
-
Hi,
I run the windows installer on SQL 2012 SP1 running windows 2012.
I encountered the error 27506, Error executing sQL script config.BaseSchema. Line 32. The create database statement failed.
The primary file must be at least 5MB to accomodate a copy of the model database. (1803)Any idea to resolve this ? Please help..thank u
Answers
-
-
Proposed as answer by
Satheesh VariathEditor
Tuesday, July 2, 2013 7:12 AM -
Marked as answer by
Fanny Liu
Friday, July 12, 2013 9:25 AM
-
Proposed as answer by
Introduction
One of my friend want a solution from me related to scripts compilation error. He is going to compile a batch job of some SQL scripts, Procedure etc and found the error mentioned bellow.
Error 27506. Error executing SQL script test.sql. Line 76. During undo of a logged operation in database ‘Test_DB’, an error occurred at log record ID(38256:32:22). The row was not found. Restore the database from a full backup, or repair the…
The Reason of this Error
The reason from this error is Data Corruption in Database
Possible Solutions
Follow the Tasks given bellow
1. Backup the Database
2. Run the following query
ALTER DATABASE test_DB SET SINGLE_USER
GO
DBCC CHECKDB (‘ test_DB ‘, REPAIR_ALLOW_DATA_LOSS) WITH ALL_ERRORMSGS, NO_INFOMSGS
GO
ALTER DATABASE test_DB SET MULTI_USER
GO
Hope it will solve the problem.
Posted by: MR. JOYDEEP DAS