Alpha Video Training
Results 1 to 6 of 6

Thread: Filter Grid Search Dropdown

  1. #1
    Member
    Real Name
    Alex Steinman
    Join Date
    Jan 2007
    Location
    Columbus, OH
    Posts
    240

    Default Filter Grid Search Dropdown

    I have a grid that is based on a table called - tbl_household_financial.

    The grid contains the household_id field, but the household_name field (which is meaningful to the user) is in a separate, related table.

    I would like to filter the search component dropdown to show only households that are in the tbl_household_financial. However, I want to display the household name in the dropdown - rather than the ID. If I base the dropdown on the tbl_household, then I can show the name (and store the ID), but I don't know how to filter the list. On the other hand, I could base the dropdown search on the tbl_household_financial and then look up the household name field.

    The problem is that I don't know how to do either - filter the list based on a variable or lookup the household name from another table.

    I appreciate any guidance.

    Thanks much.

    Alex

  2. #2
    Member
    Real Name
    Ron Leunis
    Join Date
    Sep 2005
    Location
    Netherlands
    Posts
    652

    Default Re: Filter Grid Search Dropdown

    If you use SQL DB than you can create a view over the 2 related tables and use that for your search dropdown. The filter can be applied to the dropdown over the view.

  3. #3
    Member
    Real Name
    Alex Steinman
    Join Date
    Jan 2007
    Location
    Columbus, OH
    Posts
    240

    Default Re: Filter Grid Search Dropdown

    Hmmm. Thanks, Ron. I've been thinking about switching to SQL tables.

    Is there a way to show the name and filter the list using DBFs?

    Alex

  4. #4
    Member
    Real Name
    Ron Leunis
    Join Date
    Sep 2005
    Location
    Netherlands
    Posts
    652

    Default Re: Filter Grid Search Dropdown

    Maybe by defining a set which I believe is similar using DBF... But probably others have more experience with that.

  5. #5
    Member
    Real Name
    Michael Scholin
    Join Date
    May 2007
    Location
    Madison, WI
    Posts
    321

    Default Re: Filter Grid Search Dropdown

    Since you are using Alpha dbf, you should be able to create a calculated field using lookup() or lookupc() since all you want to is display the name based on the household_id. You could use your calculated field to search against or to display.

  6. #6
    Member
    Real Name
    Alex Steinman
    Join Date
    Jan 2007
    Location
    Columbus, OH
    Posts
    240

    Default Re: Filter Grid Search Dropdown

    Thanks, Michael. That's just what I needed.

    Alex

Similar Threads

  1. Set a default value in a search part dropdown on a grid
    By den1s in forum Application Server Version 9 - Web/Browser Applications
    Replies: 3
    Last Post: 08-28-2009, 03:39 AM
  2. Session Filter in Search Dropdown Box
    By Toby Locke in forum Application Server Version 9 - Web/Browser Applications
    Replies: 0
    Last Post: 01-22-2009, 06:52 AM
  3. Put in a search on grid, go to page 2, lose the search filter (bug?)
    By clintg@erols.com in forum Application Server Version 8
    Replies: 8
    Last Post: 12-01-2007, 10:30 PM
  4. quick search dropdown filter in grid based on view.
    By Pat Bremkamp in forum Web Application Server v7
    Replies: 2
    Last Post: 07-30-2007, 08:30 AM
  5. Programming a filtered dropdown search field above the grid
    By clintg@erols.com in forum Web Application Server v7
    Replies: 10
    Last Post: 04-12-2006, 11:24 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •