Microsoft KB Archive/98792

{|
 * width="100%"|

ACC1x: Use of Constants as Field Names in a Query

 * }

Q98792

-

The information in this article applies to:


 * Microsoft Access versions 1.0, 1.1

-

SUMMARY
If you use a constant (Yes, No, True, False, On, Off, or Null) as a field name in a table and then create a query that uses any of those fields, you receive the following error message:

Invalid use of '.', '!', or '' in query expression .

where  is the name of the table you are using in the query and  is the name of the field in question.

A constant represents a numeric or string value that does not change. In some respects, a constant is like a variable or a reserved word. Unlike a variable, however, the value of a constant cannot change during program execution.

If you receive the above error message, you must change your field name at the table level.