{"id":2845,"date":"2011-06-07T07:19:37","date_gmt":"2011-06-07T07:19:37","guid":{"rendered":"http:\/\/jellywp.com\/theme\/entron\/demo5\/?p=2845"},"modified":"2011-06-07T07:19:37","modified_gmt":"2011-06-07T07:19:37","slug":"creating-site-collection-in-its-own-database","status":"publish","type":"post","link":"https:\/\/teamwp.mydevfactory.com\/abhisek-saha\/aqltech\/creating-site-collection-in-its-own-database\/","title":{"rendered":"Creating site Collection in its own Database"},"content":{"rendered":"<p>Creating site collection from CA is one of the easiest things but creating it with its own database is a little different, there are several ways to do it but I am going to do it using PowerShell:<\/p>\n<p>\/\/Get the web application in $wb variable<br \/>\n<strong>$wb = Get-SPWebApplication -Identity http:\/\/MySharePointServer:9001<\/strong><\/p>\n<p>\/\/Get the desired name of the site collection\u2019s database, we will create this DB later<br \/>\n<strong>$dbname = \u201cWss_content_MySite\u201d <\/strong><\/p>\n<p>\/\/Get url of the desired site collection<br \/>\n<strong>$SiteCollectionUrl = \u201chttp:\/\/ MySharePointServer:9001\/\u201d<\/strong><\/p>\n<p>\/\/Create the new database<br \/>\n<strong>new-spcontentdatabase $dbname -databaseserver &#8220;SP2010Database&#8221; -webapplication $wb<\/strong><\/p>\n<p>\/\/Create the site collection<br \/>\n<strong>new-spsite \u2013url $SiteCollectionUrl -owneralias MyDomain\\OwnerOfSiteCollection -Contentdatabase $dbname<\/strong><\/p>\n<p>After this is done and the first time you login to the site collection you will be prompted to select the template for the site and the users.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Creating site collection from CA is one of the easiest things but creating it with its own database is a little different, there are several ways to do it but I am going to do it using PowerShell: \/\/Get the web application in $wb variable $wb = Get-SPWebApplication -Identity http:\/\/MySharePointServer:9001 \/\/Get the desired name of [&hellip;]<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[76,77],"post_mailing_queue_ids":[],"_links":{"self":[{"href":"https:\/\/teamwp.mydevfactory.com\/abhisek-saha\/aqltech\/wp-json\/wp\/v2\/posts\/2845"}],"collection":[{"href":"https:\/\/teamwp.mydevfactory.com\/abhisek-saha\/aqltech\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/teamwp.mydevfactory.com\/abhisek-saha\/aqltech\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/teamwp.mydevfactory.com\/abhisek-saha\/aqltech\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/teamwp.mydevfactory.com\/abhisek-saha\/aqltech\/wp-json\/wp\/v2\/comments?post=2845"}],"version-history":[{"count":0,"href":"https:\/\/teamwp.mydevfactory.com\/abhisek-saha\/aqltech\/wp-json\/wp\/v2\/posts\/2845\/revisions"}],"wp:attachment":[{"href":"https:\/\/teamwp.mydevfactory.com\/abhisek-saha\/aqltech\/wp-json\/wp\/v2\/media?parent=2845"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/teamwp.mydevfactory.com\/abhisek-saha\/aqltech\/wp-json\/wp\/v2\/categories?post=2845"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/teamwp.mydevfactory.com\/abhisek-saha\/aqltech\/wp-json\/wp\/v2\/tags?post=2845"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}