Field name expressions in a query

  • Thread starter Thread starter Bill
  • Start date Start date
B

Bill

What is the syntax when creating a query field
whose value is derived from source table fields?
Example:

FullName: [mytable.firstname] & " " & [mytable.lastname]

so that when the query is run "Fullname" would be
the query field populated with the first and last name
as a single string expression.

(I tried what I gave in the example, the query builder
didn't create the single field as desired.)

Thanks,
Bill
 
Bill said:
What is the syntax when creating a query field
whose value is derived from source table fields?
Example:

FullName: [mytable.firstname] & " " & [mytable.lastname]

so that when the query is run "Fullname" would be
the query field populated with the first and last name
as a single string expression.

(I tried what I gave in the example, the query builder
didn't create the single field as desired.)


Your example has invalid syntax. Technically, I guess that
is valid, but it would be ridiculous to name a field
"mytable.firstname". The square brackets are used around a
single name. not a table and field name.

Try this:

FullName: [mytable].[firstname] & " " & [mytable].[lastname]
 
Back
Top