By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,665 Members | 1,406 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,665 IT Pros & Developers. It's quick & easy.

Question on Queries & Forms

P: n/a
Hello everybody

I have a question on running queries via a form. My situation is – I
have a query (qrysearch) and this query has a number of fields e.g.
(company, employee etc). My form is linked into the query and has the
same fields as the query. I would like to use my form as a way of
searching for records by typing in text in the appropriate text boxes
on the form.

Currently, I can link the form fields into the query, however, the
query doesn't pull back any data unless the user enters a criteria in
each of the forms text boxes. I would like to know if there is a way
of running the query without having to enter data into each text box
on the form e.g. just entering data in the ‘company' field and leaving
the ‘employee' field blank or visa versa.

Many Thanks for your assistance
Andy
Nov 13 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Andy you could use criteria like below in your query. This will return the selected record, or if
none selected will return all of them.

=Forms!frmName!fldName Or Forms!frmName!fldName Is Null

Hope this helps!
--
Reggie

----------
"Andy" <wa*********@hotmail.com> wrote in message
news:56**************************@posting.google.c om...
Hello everybody

I have a question on running queries via a form. My situation is - I
have a query (qrysearch) and this query has a number of fields e.g.
(company, employee etc). My form is linked into the query and has the
same fields as the query. I would like to use my form as a way of
searching for records by typing in text in the appropriate text boxes
on the form.

Currently, I can link the form fields into the query, however, the
query doesn't pull back any data unless the user enters a criteria in
each of the forms text boxes. I would like to know if there is a way
of running the query without having to enter data into each text box
on the form e.g. just entering data in the 'company' field and leaving
the 'employee' field blank or visa versa.

Many Thanks for your assistance
Andy

Nov 13 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.