SharePoint 2016 On-Premises

With the next version on SharePoint due sometime during the second half of this year, it’s good to hear that Microsoft are still very much continuing to provide an on-premise version. There’s been a lot of chatter recently about this being discontinued but it’s still a kicking and a screaming. See this post from earlier today – Evolution of SharePoint; definitely worth a read.

Posted in SharePoint | Tagged | Leave a comment

Shrink CrawlStore Database

A useful script for running on your dev\uat environments to free valuable disk space. The crawl store database can grow quite significantly over time.

First of all, the PowerShell script:

# Load the SharePoint assembly - change the version to 15.0.0.0 for SharePoint 2013
Add-Type -AssemblyName "Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"
 
# Reset the content index
(Get-SPEnterpriseSearchServiceApplication).Reset($true,$true)
 
# Get the database server for the default content service
$dbServer = [Microsoft.SharePoint.Administration.SPWebService]::ContentService.DefaultDatabaseInstance.NormalizedDataSource
 
# Get the SQL Management Object server for the content service retrieved above
[System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SqlServer.SMO") | out-null
$SMOserver = New-Object ('Microsoft.SqlServer.Management.Smo.Server') -argumentlist $dbServer
 
# Get the search service application instance
$searchServiceApp = (Get-SPEnterpriseSearchServiceApplication)
 
# Iterate the crawl stores and for each database, shrink it in size by 20%
foreach($crawlStore in $searchServiceApp.CrawlStores)
{		
	$dbName = $crawlStore.Name	
	$db = $SMOserver.Databases[$dbName]
	if ($db -ne $null)  
	 {  
		$db.Shrink(20, [Microsoft.SqlServer.Management.Smo.ShrinkMethod]'TruncateOnly')
		Write-Host "$dbName has been shrunk"
	 }
	 else
	 {
		Write-Host "$dbName does not exist"
	 }
}

Comments in the script should make this one clear to understand, happy coding!

Posted in SharePoint, SQL | Tagged , , | Leave a comment

Crimbo

Happy Christmas and a prosperous New Year to all! 🙂

Posted in General | Leave a comment

Workflow App Permissions

With the new 2013 workflows there are a few scenarios that can cause issues which may not be obvious to those coming from 2010. One such scenario is configuring list items to have Create and Edit access set to Create items and edit items that were created by the user and have a user who did not create the item initiate a 2013 workflow. By default, this will result in the workflow failing due to unauthorised access exceptions.

Lets walk through the scenario in more detail.

Start with creating a new custom list and then in SharePoint Designer, publish a simple List workflow to it.

Publish SPD Workflow

As you can see, a very simple workflow 🙂

Configure the list to allow users to only edit items that they created.

List Permissions
Continue reading

Posted in Designer, SharePoint, Workflow | Tagged , , | 1 Comment

Fine Grained Permissions in 2013

Setting item level permissions was straight forward in SharePoint 2010, you selected the items you wanted to break inheritance on and selected the Permissions item. When moving to SharePoint 2013 and trying to do the same thing, to a lot of users this functionality appears to no longer exist. Worry not!

To set item level permissions for an item (or multiple items) select the candidate items and switch to the Items tab in the ribbon.

Shared With

Notice the ribbon item called Shared With. This is what replaces the Permissions item from 2010. Click it and a list of users that the item is shared with loads.
Continue reading

Posted in Configuration, Security, SharePoint | Tagged , | Leave a comment