Joining fields

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Can I join fields in a query? Example I have a Home Name, a Mothers name and
a Fathers name. Can I join these in a query to show HOME, Father & Mother on
1 line?
 
Not sure if that what you mean, but to join fields together use &

As a new field in the query to join fields use
Full String: [Home Name] & [Mothers name] & [Fathers name]

To add space between the fields
Full String: [Home Name] & " " & [Mothers name] & " " & [Fathers name]
 
In query design view add below as a column in the Field row of the grid --
Family:[HOME] &", "& [Father] & " & " & [Mother]
This works unless there are some nulls.

Family: [HOME] & IIf([HOME] Is Not Null And [Father] Is Not Null,", "
& [Father],[ Father]) & IIf([Father] Is Not Null And [Mother] Is Not Null," &
" & [Mother],[ Mother])
 
Back
Top