Filtering in Business Connectivity Services from WCF Service

I have found few excellent article to define BCS Filter coming from SQL Database as per below.

But I can not find “Filter Parameter” in second step of BCS Read List operation. Also, I have difficulties to find good article on how to add filtering in BCS from WCF Service. Hence, I posted this article.

There are couple of great articles to build WCF Service that can be consumed by BCS below. It is a good starting point:

Issues

Probably some of you have the same problem or familiar with below error messages:

No Filter to select in Find drop down box.

BCS1Could not find item that is exists.

bcs21

 

Could not validate item that is exists.

bcs3

 

Resolution

1. Update your WCF Service to retrieve all records service contract to accept filter parameter (in my scenario ActiveOnly and NameFilter)

2. In SharePoint Designer > Remove existing Read List operation

3. In SharePoint Designer > Create new Read List operation from updated WCF service contract

4. Read List operation step 1, enter Operation Name and Display Name and click Next

BCS4

5. Read List operation step 2, set ActiveOnly default value to true and configure filter to NameFilter parameter, then click Next

BCS5BCS6

6. Read List operation step 3, set Id as Map to Identifier and show AffiliateName in picker, then click Finish

BCS7BCS8

7. Create new list from External Content Type & Ensure the list retrieving records

BCS9

8. Create / Update your list to add / update External data column to new External Content Type list

9. Ensure it has “Name” in filter drop down box and could validate existing item works

BCS10

bcs11

bcs12

Advertisements

Tagged: , , , , , , , , , , ,

2 thoughts on “Filtering in Business Connectivity Services from WCF Service

  1. Sebastian Fernandez 08/29/2014 at 1:50 PM Reply

    how do i do for have more than one filter. for examploe: “Name”…”LastName…etc

    • tjenho 08/29/2014 at 10:07 PM Reply

      Your wcf service needs to accept multiple filter parameters. Then you just add new filter in bcs configuration. So the drop down box will have name and last name? But you only filter based on one field. Either by name or last name.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: