How to: Create a BCS Profile Page in SharePoint 2010

Posted Thursday, April 15, 2010 3:36 PM by CoreyRoth

I was working on updating my Search demo for #spshou and my BCS search results were really ugly.  I didn’t have a default action specified on my search results, nor did I have a profile page, so instead the search results would give me the BDC protocol URL which is not usable by an end user. 

BCSSearchResults

In MOSS 2007, if you did not create a default action, it would automatically create a profile page for you.  In SharePoint 2010, this is not the case.  It’s pretty easy but there are a few steps involved.

Start by opening SharePoint Designer and open your external content type in question.  In the top right, you will find the Create Profile Page button. 

BCSSharePointDesignerNewProfilePageButton

Give it a click.  However, if you haven’t configured a profile host URL, you will get the following error.  Chances are you haven’t configured one of these yet.

BCSSharePointDesignerProfilePageError

Unable to provision profile page because the profile host URL was not specified.

After doing a search, I found only one usable result on the Internet on MSDN forums.  It had the answer, but it wasn’t clear to me at first.  It said to use the Configure button in the ribbon.  However, I was looking in SPD, and in fact its in the Service Application instead as you can see below.

BCSServiceApplicationConfigureButton

Select the application you want to edit and then you can click Configure.  This brings up the popup shown below which prompts you for a URL of the site that to keep you profile pages in.  I like this since you can configure these at a per application definition level now instead of one location for every entity on the SSP.

BCSConfigureProfileSite

I decided that I wanted my profile pages in a specific subsite, so I went ahead and created a new one.

BCSProfileNewProfileSite

After I finished configuring my site and setting up the Profile Page Host, I was able to go back to SPD and click the button.  This pops up a progress bar, but it doesn’t really give you any visual indication that anything is done.  I then went back to my content sources and recrawled my BCS content source.  When it finished, I executed a new search, and now I get actual usable URLs in my search results.

BCSSearchResultsProfilePage

As you can see it generated kind of a long URL with _bdc in it.  I believe the http and sp2010 come from the namespace specified in SharePoint Designer.  Finally it names a page after the entity itself.  So far, I’m not sure if any of the page name stuff is configurable or not, so I need to look into that.  Once you click on the page, you get a simple profile page to display the results.

BCSProfilePageComplete

It’s simple, but it has all the pertinent information from the underlying database table.  It beats what I had before.  I think a custom default action can be specified just like in MOSS 2007, but I get the feeling you have to edit the application definition XML manually to make it happen.  I’m still looking into it.  Anyhow, I hope this helps, the next time you try to use the BCS.

Comments

# re: How to: Create a BCS Profile Page in SharePoint 2010

Thursday, June 10, 2010 10:23 AM by Nils

Oh my god - I just spent a few hours trying to find this solution! - The german translation of the error speaks of a hostwebsite (ridiculously the error message is in english)

Thank you very much for finally giving me this :)

# re: How to: Create a BCS Profile Page in SharePoint 2010

Friday, September 3, 2010 4:09 AM by Pogo

Hello,

I have no Search Service on my site...

How can I access to my _bdc Folder?

How the Profile Page's URL is it built?

Thanks.

# re: How to: Create a BCS Profile Page in SharePoint 2010

Tuesday, September 7, 2010 12:17 PM by CoreyRoth

@Pogo The profile page URL is built once you configure the URL on your service application.  The _bdc folder is autogenerated once you create a profile page.

# re: How to: Create a BCS Profile Page in SharePoint 2010

Wednesday, September 8, 2010 1:32 PM by Brent

Does anyone have steps to perform this via powershell?

# re: How to: Create a BCS Profile Page in SharePoint 2010

Monday, September 27, 2010 1:50 PM by Brent

Please find details on the PS steps to create the profile page.

Add-PsSnapin Microsoft.SharePoint.PowerShell -erroraction SilentlyContinue

# Create the profile page

$url = "http://gr06"

$context = Get-SPSite $url | Get-SPServiceContext

# Do not use these commented out constructors. There is currently a bug in the BdcServiceApplicationProxy contstructor where the AppId is not set.

# Therefore, the ProfileProvisioner constructor doesn't get called with a valid bdcproxy object. It's not obvious that there was a problem until the CreateProfilePage call.

# At which point there is an error message: Exception calling "CreateProfilePage" with "2" argument(s): "Object reference not set to an instance of an object."

#$bdcproxy = New-Object Microsoft.sharePoint.BusinessData.SharedService.BdcServiceApplicationProxy

#$profileProvisioner = New-Object Microsoft.SharePoint.Portal.WebControls.ProfileProvisioner($bdcproxy, $MetadataStore)

$profileProvisioner = New-Object Microsoft.SharePoint.Portal.WebControls.ProfileProvisioner($context)

$res = $profileProvisioner.CreateProfilePage("Microsoft.Lobi.OracleModel","employee")

# re: How to: Create a BCS Profile Page in SharePoint 2010

Wednesday, October 20, 2010 4:20 PM by aaron witt

so, i've created the standard display/edit/new forms on an external content type list.  i've also created a profile page as a default action on the ect in question.  i am trying to accomplish two things with this setup:

1.) have the default link from the readlist be to the profile page, rather than the display form - i do not want to use the display form at all. i'd like all content type interactions to occur from the profile page, as it displays all pertinent data (i.e. associations, attributes, etc.)

2.) from the profile page, have two links for both editing the current content type instance and a link for creating a new instance of the content type in question.  i want the two links i just described to use the standard edit/new forms already created for the ect list.

how can i accomplish either one of these goals?  i'm finding that editing default webparts (specifically the readlist) is quite difficult and not at all straightforward.  any help would be greatly appreciated on this.  thanks.

# re: How to: Create a BCS Profile Page in SharePoint 2010

Thursday, June 16, 2011 6:01 AM by Josep

Does anyone tried to change the profile page url? Does it work?

For example, instead of having:

dsglespbr-s4019/.../Articles_DEV_2.aspx{0}

change it for:

dsglespbr-s4019/.../Articles.aspx{0}

# re: How to: Create a BCS Profile Page in SharePoint 2010

Monday, June 20, 2011 4:11 PM by CoreyRoth

@Josep I think that should work.

# re: How to: Create a BCS Profile Page in SharePoint 2010

Tuesday, September 13, 2011 2:34 AM by Chintu

In my project, Profile Page is enabled for search and search result page gives the list items with ...\profilepage url. Now client does not want search to be displayed in profilepage, instead wants these search URLs to point to EditForm web part. I have used custom web part developed in silverlight for Edit.

How can I do this in 2010?

# re: How to: Create a BCS Profile Page in SharePoint 2010

Thursday, September 15, 2011 5:23 PM by CoreyRoth

@Chintu go to your BCS service application, edit the bcs connection and you will be able to create a custom action.  Create a new action with a URL that points to your Silverlight edit page.  Make sure it is the default action and then recrawl.

# re: How to: Create a BCS Profile Page in SharePoint 2010

Tuesday, October 25, 2011 8:38 AM by Alex

Thanks much for the article - made my day after multiple hours of trying figuring it out

# re: How to: Create a BCS Profile Page in SharePoint 2010

Tuesday, November 15, 2011 8:15 AM by sireesha

Hi Corey,

I am using sharepoint 2010 Business connectivity service. I need to search an item in the database. So I configured search service. I am able to find the search results but when I clicked on the results , the URL starts from bdc3:// instead of going to profile page. The error showed on the page is "web page cannot be displayed". Please guide me to resolve this problem.

Appreciate your help.

# re: How to: Create a BCS Profile Page in SharePoint 2010

Wednesday, December 7, 2011 8:40 PM by CoreyRoth

@sireesha If you can search the data, you may just need to reindex after you have created the profile page.  If it works correctly, you will see the profile page URL in the crawl logs.

# BCS Create Profile Page « Sladescross's Blog

Tuesday, January 24, 2012 10:51 AM by BCS Create Profile Page « Sladescross's Blog

Pingback from  BCS Create Profile Page « Sladescross's Blog

# BCS Create Profile Page « Sladescross's Blog

Tuesday, January 24, 2012 10:51 AM by BCS Create Profile Page « Sladescross's Blog

Pingback from  BCS Create Profile Page « Sladescross's Blog

# re: How to: Create a BCS Profile Page in SharePoint 2010

Tuesday, November 27, 2012 9:05 AM by mhu

"Finally it names a page after the entity itself.  So far, I’m not sure if any of the page name stuff is configurable or not, so I need to look into that"

Have you been able to look into this?

I use search.asmx for searching, and the returned Title, Path and Filename properties all point to the Products_1.aspx page instead of the fields from the BDC datasource.

# re: How to: Create a BCS Profile Page in SharePoint 2010

Wednesday, October 16, 2013 3:39 AM by Henning

The page name displayed in the search results is indeed configurable from SharePoint Designer. Open your external content type, click any one of your fields that you would like to be set as the search title and click 'Set as Title' in ribbon. Bingo!

Leave a Comment

(required)
(required)
(optional)
(required)