Partilhar via


BDC Model: FAQ

This topic answers some frequently asked questions about the BDC model.

Applies to: SharePoint Server 2010

In this article
Why does the Update operation fail with the error "The Field named 'CustomerId' is provided as input but cannot be found on the 'Updater' method signature for Method with Name 'UpdateCustomer' on Entity with Name 'Customer' in Namespace 'WestCoastSales'"? Create and Delete operations work fine.
I created a BDC model for web services hosted on Internet Information Services (IIS), where only Basic Authentication is enabled. Now when I try to access the WSDL for this web service through a browser, a form appears requiring a user name and password. How can I pass credentials in this case in a secure way, so that I can import the BDC model successfully in SharePoint?
How can I see the SOAP requests and responses between the BDC on one computer and web services on another computer?
Why can't others view my external list? Instead, they get the error "Unable to display this Web Part. To troubleshoot the problem, open this web page in a SharePoint Foundation-compatible HTML editor such as Microsoft SharePoint Designer. If the problem persists, contact your web server administrator."
How should I name a BDC model file?

Why does the Update operation fail with the error "The Field named 'CustomerId' is provided as input but cannot be found on the 'Updater' method signature for Method with Name 'UpdateCustomer' on Entity with Name 'Customer' in Namespace 'WestCoastSales'"? Create and Delete operations work fine.

You are encountering this problem because even though your identifier is not marked as read-only your Update method cannot update the identifier value.

If your identifier should be read-only, solve this issue by marking all the TypeDescriptor elements that correspond to the identifier in output parameters as ReadOnly = "true".

Note

Your identifier remains read-only when the item is being created and can be set by the user, but it cannot be changed after it is created.

If your identifier should not be read-only, then the reason for this error might be that your external system APIs are incorrect. This can mean one of the following:, or.

  • The Update method cannot update this specific identifier.

  • Your model is incorrect because the identifier is incorrectly specified.

  • There are multiple sets of identifiers in your entity and each set can distinctly identify an EntityInstance, which is not supported.

Note

For the identifier to be updateable, the external system must get the previous value and the new value of the identifier in the method signature.

I created a BDC model for web services hosted on Internet Information Services (IIS), where only Basic Authentication is enabled. Now when I try to access the WSDL for this web service through a browser, a form appears requiring a user name and password. How can I pass credentials in this case in a secure way, so that I can import the BDC model successfully in SharePoint?

You can use the Secure Store to pass the credentials. Set the credentials mode to Credentials in the BDC model, and populate the user identifier or password in the Secure Store for the corresponding target application.

How can I see the SOAP requests and responses between the BDC on one computer and web services on another computer?

Windows Communication Foundation (WCF) provides its own infrastructure for this purpose to log messages and trace activities. You are probably interested in message logging, not activity tracing. Logging is configured by making changes to the web.config file. For more information, see Configuring Message Logging.

Note

Client-side message logging (SOAP response) is configured by changing the web.config file for the client binding. Server-side logging (SOAP request) is configured by changing the web.config file for the Web App that hosts your service. You can view the logged messages by using SvcTraceViewer.exe. For more information, see Service Trace Viewer Tool (SvcTraceViewer.exe).

Why can't others view my external list? Instead, they get the error "Unable to display this Web Part. To troubleshoot the problem, open this web page in a SharePoint Foundation-compatible HTML editor such as Microsoft SharePoint Designer. If the problem persists, contact your web server administrator."

There could be several reasons for this error. For example, others might not have access to the external system or to the metadata.

If a user is getting an access denied error because he or she does not have access to the metadata (by default, only you do), you can change the access control list (ACL) in your model or external content type to give the user "Execute" rights. The easiest way to do this is to use the BDC Administrative User Interface in SharePoint Central Administration to set permissions and propagate those permissions to child objects on the external content type. If you must control rights on a more granular level, you can export resources for the model (including only permissions), change the permissions, and then reimport the resources.

How should I name a BDC model file?

Using Microsoft Business Connectivity Services (BCS), you can generate a BDC model by using Microsoft SharePoint Designer 2010, Microsoft Visual Studio 2010, or the BDC Administrative User Interface in SharePoint Central Administration. When the model is generated, it is appended with a .bdcm file name extension.

A requirement of Business Connectivity Services solution deployment is that the BDC model that is included with the solution be named metadata.xml. The BCS Solution Packaging Tool accepts a model of this name or a BDC model with the .bdcm file name extension. However, if you choose to create your own packaging tool or you want to manually add a post-deployment action for ClickOnce Microsoft Office solutions that are created with Microsoft Office development tools in Microsoft Visual Studio 2010, you must rename the BDC model metadata.xml instead of using the default .bdcm file name extension.