StrataFrame Forum

BrowseDialog with BO question

http://forum.strataframe.net/Topic7543.aspx

By StarkMike - 3/16/2007

I have a BrowseDialog that is based on a BO that is based on a view and when I click 'Ok' in the browse dialog I get this error:



"The PrimaryKeyFields property must have exactly 1 field to use the PrimaryKeyField property."



Because the BO is based on a view there really isnt a primary key... not sure what to do from here just looking for some guidance. ;-)
By Trent L. Taylor - 3/16/2007

This is why we added the ability to override the primar key through the BO mapper....for BOs that are based on views.  To set a primary key field do the following:

  1. Open the BO Mapper
  2. Select the BO which is based on the view
  3. Open the BO properties
  4. Show the Advanced Options
  5. Click the Override Primary Key Specification
  6. Choose the field which will "act" as the primary key
  7. Click OK
  8. Rebuild the partial

You now have a BO based on a view with a primary key Smile

By StarkMike - 3/16/2007

GREAT! Thanks!