I am just in the process of writing some PowerShell Scripts to import Managed Metadata Properties and Crawled properties from an XML configuration file and came across a small point that I felt needed recording.
I will probably write a fuller post with the XML Config, XSD schema and Powershell components later, when I have finished and tested it, but wanted to provide this bit straight away.
I won’t go into the details of the PowerShell here as Corey Roth has already given the basics here:
One bit that he is missing is the -Type value that you pass into the following cmdlet ‘New-SPEnterpriseSearchMetadataManagedProperty‘
According to Technet (http://technet.microsoft.com/en-us/library/ff608089.aspx) it should be one of the following ‘Int32’ values
I think you see the problem?
So, What we need to pass into the -Type parameter for that cmdlet is the Int32 value for those types. Corey didn’t gt round to working them out, so I have got them here:
Hope this helps.