query on multiple fields

  • Thread starter Thread starter Rooney
  • Start date Start date
R

Rooney

I'm building a simple database where I'm gathering info
on corporations from public databases. Several names are
in several fields such as CEO, CFO, SEC. I've built a
table on the corporations where I enter the names in four
fields:
CEO
CFO
SEC
Regagent

I'd like to build a query on all the name fields so that
I can build a combobox with all the names to select from.
Is there a way to do this?

Thanks in advance.

Meg
 
I'm building a simple database where I'm gathering info
on corporations from public databases. Several names are
in several fields such as CEO, CFO, SEC. I've built a
table on the corporations where I enter the names in four
fields:
CEO
CFO
SEC
Regagent

I'd like to build a query on all the name fields so that
I can build a combobox with all the names to select from.
Is there a way to do this?

Yes; use a criterion of

=Forms!NameOfForm!NameOfCombo

under each field, on *separate rows* of the query grid so it uses OR
logic.

I'd really suggest a different design, however; you're storing data in
fieldnames, which is never a good idea. You might want to have a
second table Officers with fields

CorporationID < link to your current table
OfficerType < e.g. "CEO", "CFO", "Chief Cook and Bottle Washer"
OfficerID < link to a People table with names & biographical data

This would allow for one person serving on several corporations (e.g.
as a member of the board of directors), and let you search just one
field rather than several.
 
Back
Top