Query

  • Thread starter Thread starter Deborah Rylands
  • Start date Start date
D

Deborah Rylands

I am trying to query using a "where" criteria. I want
data from a table only if the field is equal to a field
on the form. Is this possible? Eg. When the "size"
field in the table is equal to the "size" field on the
form, I want it to bring back the last value.
 
I am trying to query using a "where" criteria. I want
data from a table only if the field is equal to a field
on the form. Is this possible? Eg. When the "size"
field in the table is equal to the "size" field on the
form, I want it to bring back the last value.

Create a Query based on the table. On the criteria line under [Size]
put

=[Forms]![NameOfYourForm]![txtSize]

where txtSize is the textbox you're using as a criterion.

Note that this must be an UNBOUND textbox - its Control Source should
be blank; otherwise you'll change the value in the currently selected
record on your table in the process of entering the criterion!
 
Back
Top