Adding new attributes programmatically to the Metaverse is currently not supported by FIM in any of its forms, however, if you are willing to take the chance and make the changes needed directly to the database, this is possible. This isn't necessary recommended and it is definitely not for the faint of heart. However, if you are determined to give it a try, here is what you have to do. First, make a backup of your database, then:
For single-valued non-reference attributes:
- Add a column to the mms_metaverse table with the appropriate name and data type
- Add a column to the mms_metaverse_lineagedate table with the appropriate name and a data type of datetime
- Add a column to the mms_metaverse_lineageguid table with the appropriate name and a data type of uniqueidentifier
- If you want the attribute to be indexed - add a new non-unique, non-clustered index to the mms_metaverse table with the name IX_mms_metaverse<attributeName>
Then, for all attributes (single or multi, reference or not) you will then need to:
- Update the mv_schema_xml column of the mms_server_configuration
- Close the client, restart the Sync Service and re-open the client
I have only done some preliminary testing, but so far it has worked okay. I have worked out a SQL Script to help you through the process. Its called MVAttributeCreationScript.sql and you an download it from http://sdrv.ms/11oBRr8.
If you are uncomfortable attempting to update the schema in this fashion, there are a couple of other possibilities. However, these also carry their own risks:
- Export the MV Schema, update the xml export file and then re-import it
- Create a key stroke script to perform the updates through the UI as a user would
I will create some additional blog posts to expound on these two methods a little bit further, so be on the lookout!