July 11, 2013 at 7:21 am
based on a previous post here, someone had a quesiton on Contained databases, so i decided to create one myself to follow along.
BOL says the settings for the database containment can be NONE, PARTIAL or FULL.
When you create a database via the GUI, you only get a selection for PARTIAL or NONE.
so how do you create a fully contained database?
if i use the scripting option, and try to modify the script to say FULL, i get a syntax error.
Msg 156, Level 15, State 1, Line 2
Incorrect syntax near the keyword 'FULL'.
Msg 911, Level 16, State 1, Line 1
Database 'FullyContained' does not exist. Make sure that the name is entered correctly.
CREATE DATABASE [FullyContained]
CONTAINMENT = FULL
ON PRIMARY
( NAME = N'FullyContained', FILENAME = N'F:\SQLData\SQL2012\FullyContained.mdf' , SIZE = 4096KB , FILEGROWTH = 1024KB )
by the way, my Google-Fu is strong, and everything i see in BOL so far shows changing a database from None to Partial, but nothing for Partial to FULL or None to FULL
LOG ON
( NAME = N'FullyContained_log', FILENAME = N'F:\SQLData\SQL2012\FullyContained_log.ldf' , SIZE = 1024KB , FILEGROWTH = 10%)
Lowell
July 11, 2013 at 7:38 am
Lowell (7/11/2013)
So how do you create a fully contained database?
You don't. 2012 only allows partially contained.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply