title: How to show only a subset of a table
body: <p>I am having an issue populating a data table with the correct data.</p>
  
  <p>I have a Data Table that I am using in a form.  It is called userConfigProfiles.  It has a 2 FK columns groupId(this joins to UserGroupInfo) and corpProfileId(this joins to a table I created).  That data in userConfigProfiles is populated from another form and is currently populated appropriately.</p>
  
  <p>The issue is, I need to create a drop down on the SalesTable form that shows a subset of the rows in userConfigProfiles based off of what UserGroups the current user is in.</p>
  
  <p>I tried to do this by adding the below code to the table, userConfigProfiles in the SalesTable form:</p>
  
  <pre><code>public void init()
  {
      userConfigProfiles.data(userConfigProfiles::find());
  
      super();
  }
  </code></pre>
  
  <p>Then I added this find method to the Table itself:</p>
  
  <pre><code>static public userConfigProfiles find()
  {
      userConfigProfiles userProfile;
      UserGroupList userGroupList;
  
      str 8 u = curUserId();
  
      select *
      from userProfile
      order by userProfile.bdcProfileId
          join userGroupList
      where userProfile.groupId == userGroupList.groupId
          &amp;&amp; userGroupList.userId == u;
  
      return userProfile;
  }
  </code></pre>
  
  <p>However, it appears that even though my find method is called and it returns the correct data it is not affecting the data that goes into the drop down list on my form.</p>
  
  <p>My drop down list is a StringEdit field with a DataSource of userConfigProfiles and a DataField of corpProfileId.</p>
  
  <p>I am pretty sure there are several ways to solve my problem and I am open to any of them, even if it means removing all of my code and doing the drop down box completely differently.</p>