Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

How to: Convert an app-scoped external content type to tenant-scoped

SharePoint 2013

Learn how to create an OData-based external content type using Visual Studio 2012 auto-generation tools and import it into the Business Connectivity Services (BCS) metadata store so that it can be used across an entire tenant workspace.

Applies to:  SharePoint Server 2013 | Visual Studio Tools for Microsoft Office | apps for SharePoint 

BDC models are complex XML definitions of an external data source. They are used when defining external content types for BCS. They are very difficult to build manually, so tools have been built to automatically generate the files using Visual Studio 2012 and Office Developer Tools for Visual Studio 2012. Using these tools, you can create an .app package using Visual Studio publishing, and then open that package to extract the model file.

The following steps show you how to create the OData-based external content type and then import it into the BCS metadata store so that it can be used across an entire tenant workspace.

To create a BDC model file from an OData source

  1. In Visual Studio 2012, create an App for SharePoint 2013 project.

  2. Specify the app settings, including app name, the site URL for debugging the app, and how you want to host the app (Autohosted, Provider-hosted, or SharePoint-hosted). For more information, see Choose patterns for developing and hosting your app for SharePoint.

  3. Choose Finish to create the app.

  4. In Solution Explorer, open the shortcut menu for the project, and choose Add, Content types for External Data source.

    This starts a wizard that helps you find the selected data source and create the BDC model.

  5. On the Set OData Source page, enter the URL of the OData service that you want to connect to. The URL should look something like this: http://services.odata.org/Northwind/Northwind.svc/.

    Specify a name for your OData source.

    Note Note

    For this example, you will use the Northwind service that is available from the producers list located on the Open Data Protocol website.

  6. A list appears showing data entities that are being exposed by the OData Service. Select one or more of the entities, and choose Finish.

To deploy the app-scoped external content type as an app package

  1. In Visual Studio, on the Build menu, choose Publish.

  2. Name the package, specify the save location on your local hard drive, and choose Finish.

To extract the model file from the .app package

  1. Open the folder where the .app package is created.

  2. Change the file name extension from .app to .zip.

  3. Extract the ZIP package to a local folder.

  4. Open the extracted folder to find the WSP file.

  5. Move the WSP file to another location.

  6. Change the .wsp file name extension on this file to .cab.

  7. Open the .cab file, and you will find the Bdcmodel.bdcm file.

  8. Save the Bdcmodel.bdcm file to another location.

To import the model file using SharePoint Central Administration pages

  1. Open SharePoint Online or SharePoint 2013 on-premises Central Administration pages.

  2. Choose Manage serve applications.

  3. Choose Business Data Connectivity Service.

  4. Choose the Import link on the server ribbon.

  5. Choose the Browse button to specify the location where you extracted the .bdcm file.

  6. Keep the default settings, and then choose Import.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.