Self Referencing Tables

2 posts, 0 answers
  1. lkeel
    lkeel avatar
    115 posts
    Member since:
    Jul 2012

    Posted 27 Jul 2009 Link to this post

    It would be great if there was a better naming convention for self referencing tables.  For Example:  I have a group table and you can have a group contain other groups.  So in order to achieve this, I have added a ParentID column.  The problem is that OpenAccess names this property as Group1.  It would be better if it would name it ParentGroup.  It seems to me (at least in my narrow world) that if a table is self-referencing, then it is most likely trying to create a parent-child relationship so the parent is referenced by the child.  If the default naming convention could not be accomodated, then some way to validate\display\edit all properties for classes within the project that have a 1 at the end would be acceptable.
  2. Ady
    Admin
    Ady avatar
    589 posts

    Posted 29 Jul 2009 Link to this post

    Hello lkeel,

     We have scheduled a better default naming mechanism for reference fields, where the field name is derived from the FK column name and not the referenced type name. So if you have 'ParentGroupId' column that is self referencing, the generated field would be 'parentGroup' and not Group1.

     Currently there is no UI to view/edit all fields that end with 1 but you can expect the improvement in one of the next service packs.

    Kind regards,
    Ady
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  3. DevCraft banner
Back to Top