{"id":3446,"date":"2015-12-16T10:00:03","date_gmt":"2015-12-16T15:00:03","guid":{"rendered":"https:\/\/academy.sqlbak.com\/?p=3446"},"modified":"2023-10-17T04:55:25","modified_gmt":"2023-10-17T08:55:25","slug":"create-database-failed-some-file-names-listed-could-not-be-created-msg-1802","status":"publish","type":"post","link":"https:\/\/academy.sqlbak.com\/create-database-failed-some-file-names-listed-could-not-be-created-msg-1802\/","title":{"rendered":"CREATE DATABASE failed. Some file names listed could not be created (Msg 1802)"},"content":{"rendered":"
The error “CREATE DATABASE failed. Some file names listed could not be created. Check related errors.<\/em>” can occur when the user tries to create a database with file names specified. To understand when this error can appear and how to avoid it, let’s consider the following syntax:<\/p>\n <\/p>\n In this case, the SQL Server will send the following errors:<\/p>\n The reason why this error appeared is that one of the file parameters is incorrect. In this case, the user set up the size of the data file to zero.\u00a0Msg 5174 gives a hint that\u00a0Each file size must be greater than or equal to 512 KB.<\/p>\n","protected":false},"excerpt":{"rendered":" The error “CREATE DATABASE failed. Some file names listed could not be created. Check related errors.” can occur when the user tries to create a database with file names specified. To understand when this error can appear and how to avoid it, let’s consider the following syntax: CREATE DATABASE Adventureworks ON PRIMARY ( NAME = […]<\/p>\n","protected":false},"author":10,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[159],"tags":[],"yoast_head":"\nCREATE DATABASE<\/span> Adventureworks \r\nON PRIMARY<\/span>\r\n( NAME = Adventureworks_Data,\r\n\u00a0 FILENAME<\/span> = 'Adventureworks_Data.mdf'<\/span>,\r\n\u00a0 SIZE = 0,\r\n\u00a0 MAXSIZE = 30,\r\n\u00a0 FILEGROWTH = 10% )\r\nLOG<\/span> ON<\/span>\r\n( NAME = Adventureworks_Log,\r\n\u00a0 FILENAME<\/span> = 'Adventureworks_Log.ldf'<\/span>,\r\n\u00a0 SIZE = 3MB,\r\n\u00a0 MAXSIZE = 20MB,\r\n\u00a0 FILEGROWTH = 3MB );\r\nGO<\/span><\/pre>\n
Msg 5174, Level 16, State 1, Line 2<\/span>\r\nEach file size must be greater than or equal to 512 KB.<\/span>\r\nMsg 1802, Level 16, State 1, Line 2<\/span>\r\nCREATE DATABASE failed. Some file names listed could not be created. Check related errors.<\/span><\/pre>\n