How do I store this external data in SharePoint?

262 views Asked by At

I am using Visual Studio 2010, SharePoint 2010 with custom document content types and forms. And plan to also use jquery to build the document add/edit/view forms.

I am developing a solution where I want to have a document library where each document uploaded also has a number of external data elements added as metadata.

The tricky part I'm trying to figure out is I want the user to be able to specify and add a multiple number of those same external data elements.

I'm trying to figure out how I represent the data internally in SharePoint. My initial thought is to programmaticly add hidden external fields as the users adds those external selections. But then I also think of simply storing those external elements as non-external text fields but have my own code which performs the external data lookup and validation.

I'm not adverse to significant custom coding, as I'm probably going to need to do a lot anyway since even the user interface is going to be a jquery tabbed form to enable all the external data the user will be able to associate with each SP document.

I've made an attempt to hopefully further explain what I'm trying to do and included that image. Essentially I'm wanting to add 1+ external data relationships to each document, as desired by the user.

It uses just example data. I'll actually have 4-7 different complex relationships much like the example. And the user is permitted to drilldown and select 1, 2 or all 3 of the dropdowns.

Think of it as similar to how here on Experts-Exchange we can add multiple zones to a question.

An example illustration is here: http://flic.kr/p/aFUSJn

2

There are 2 answers

0
Josey On

Could you simply add a multi-line text column and have the user input the metadata with comma's, then use your code to seperate the data and do what you want with it?

0
Shiraz Bhaiji On

You said you were not adverse to significant custom coding :)

One solution is to use SharePoint content types. The trick is that not all items in a list need to have the same content type.

Therefore, you can do the following:

  • As the user is selecting the fields he wants to use you generate or select a content type that matchs those fields.
  • You then add your document to the document list using the content template

You then have all your information strongly typed in SharePoint lists.

We have previously built a system where we generate content types based on xsd files, this worked very well.