Results 1 to 2 of 2
  1. #1
    5 Star Lounger
    Join Date
    Jan 2001
    Thanked 0 Times in 0 Posts

    IIF statement (2000)

    I have a query that has a field called Counties.
    I have to break this field down according to Region.
    I would like to create a Region column in the query.
    There are about 5 regions - "Special Accounts", "2-19 Book", "North Central Region", "Lehigh Valley Region", "South Central Region"
    I want to use the IIF statement but I am not sure.
    It would be something like - IIF county in (Berk, Allegheny, etc), "Special Accounts", ? then I have to define the other counties according to what region they are in.

    I am not sure this is the best approach. Is this a nested IIF and if so how do I set it up. Thanks for any help you can provide.

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Thanked 31 Times in 31 Posts

    Re: IIF statement (2000)

    Do you already have a table that lists the (unique) counties? If so, add a Region field to this table. If not, create a table with two fields: County and Region.

    <table border=1><td align=center>County</td><td align=center>Region</td><td>Berk</td><td>Special Accounts</td><td>Alleghany</td><td>Special Accounts</td><td>...</td><td>...</td></table>
    You can add this table to your query, linked to the table that is already there on County, and drag the Region field to the query design grid.

Posting Permissions

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