Help with syntax for passing a field value to a lookup query?

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



I am trying define a lookup field in a table where the values displayed
depend on the content of an adjacent field.
For example:

Lookup Table:
State-------City
AZ--------Phoenix
AZ--------Tempe
CA--------Los angeles
CA--------San Francisco

If the state field in the primary table contains AZ, I want the lookup combo
box to display only Phoenix and Tempe...

What is the correct syntax for passing a value from a field in the primary
table to a lookup query? When I use "[table].[field]" I get a prompt for a
value when the table is opened. When I use "table![field]", the lookup combo
box contains no entries.

I used to know how to do this, but I forgot..

Thanks,

Keith


.



Relevant Pages

  • Need help with GridView and LDAP/GC
    ... I could do the search with GC, and then lookup more ... DirectoryEntry searchRoot = new ... // Add search string if specified. ... // Display Name ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: displaying an "alias" value in a table
    ... In the lower pane of the table design window, click on the Lookup tab. ... You will see that it is set up as a Combo, where the bound column is ... HOWEVER the table field display substitutes the information in ... For instance I might select "Mary Ann" from a dropdown list. ...
    (microsoft.public.access.tablesdbdesign)
  • Re: SQL "NOT IN" doesnt function as expected (refresh)
    ... The unfortunate fact is that what is displayed in datasheet view of a query is not what is stored if you are using a field that uses the lookup feature. ... That's why most of us avoid using the lookup field. ... On forms you can use a combobox to display one value while actually storing another value. ... implementation of the form is -supposed- to be independant of the underlying storage, otherwise it makes a mockery of the SQL standard. ...
    (microsoft.public.access.queries)
  • Re: LOOKUP mayhem
    ... Vlookup does not lookup multiple values, only goes to the first one ad the ... Perhaps you can use a helper column to the left of the current data and ... and a row will display the updates (if any are ...
    (microsoft.public.excel)
  • Re: Convert
    ... create a separate table that stores the code and translation and then ... The advantage with the lookup table is that should you ever ... Set the .RowSourceType to 'ValueList'. ... store the code but display the translation. ...
    (comp.databases.ms-access)