Working with External Content Types and Lists - Exercise

Contact Us or call 1-877-932-8228
Working with External Content Types and Lists - Exercise

Working with External Content Types and Lists

Duration: 15 to 25 minutes.
  1. Navigate to your team site.
  2. Open your site in SharePoint Designer.
  3. Create a new External Content Type mapped to the Northwind database Products table.
    1. Click the External Content Types link in the Navigation pane of SharePoint Designer. Exercise - Business Connectivity Services
    2. Click the External Content Type button in the External Content Types tab toolbar inside the New group. Exercise - Business Connectivity Services
    3. Click the New external content type link next to the Name label in the External Content Type Information area of the New External Content Type tab editor. Exercise - Business Connectivity Services
    4. Type "<<your name goes here>>-ProductsECT" in the Name field; your name is to make sure the External Content Type is unique within your farm.Exercise - Business Connectivity Services
    5. Click the Click here to discover external data sources and define operations link next to the External System label. Exercise - Business Connectivity Services
    6. Click the Add Connection button on the Operation Designer editor. Exercise - Business Connectivity Services
    7. Select SQL Server in the Data Source Type and click the OK button on the External Data Source Type Selection dialog. Exercise - Business Connectivity Services
    8. Type the name of a SQL server that has a copy of the Northwind database in the Database Server field, "northwind" in the Database Name field, "<<your name goes here>>-Northwind" in the Name (optional) field and click the OK button to save and close the SQL Server Connection dialog. External Content Types
    9. Expand the northwind database by clicking the "+" icon in the Data Source Explorer tab. Exercise - Business Connectivity Services
    10. Click the "+" icon next to the Tables item in the Data Source Explorer tab to expand the tables list.
    11. Right-click the Products table and choose the Create All Operations option. Exercise - Business Connectivity Services
    12. Click the Next button on the first page of the All operations dialog. Exercise - Business Connectivity Services
    13. Click the Next button on the second page of the All operations dialog. Exercise - Business Connectivity Services

      You can use this page to remove fields you don't want to expose through SharePoint. Additionally, you can set properties of each field such as the Display Name, which is used to create labels for displaying the data.

    14. Click the Finish button on the last page of the All operations dialog. Exercise - Business Connectivity Services
    15. Click the Save icon in the upper-left corner of SharePoint Designer's window to save the External Content Type to the Business Connectivity Service of the SharePoint farm. Exercise - Business Connectivity Services
  4. Create a new SharePoint list from the <<your name goes here>>-ProductECT content type.
    1. Click the Create Lists & Form button on the External Content Types tab toolbar. Exercise - Business Connectivity Services

      You can also create the External List using the browser as was done in the walk-though earlier in this lesson.

    2. Type "Products" in the List Name field and click the OK button. Exercise - Business Connectivity Services
  5. Open the Products list in the browser and edit an item.
    1. Switch back to your browser window and click the Contoso Home Site link to refresh the page so the Products link will show in the Quick Launch. Exercise - Business Connectivity Services
    2. Click the Products link in the site's Quick Launch menu. Exercise - Business Connectivity Services
    3. Verify the Products list shows the data from the Northwind database Products table.
    4. Click the ellipsis link to the right of the first Products item with the ProductID of "1" and choose Edit Item from the drop-down options. Exercise - Business Connectivity Services
    5. Change the UnitPrice field to "20.0000" and click the Save button. Exercise - Business Connectivity Services
    6. Verify the Products item shows "20.0000" for the UnitPrice field back in the main view of all items. Exercise - Business Connectivity Services
  6. Close SharePoint Designer.
Next