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

how can I bypass my query parameter

P: n/a
This is probably a really silly question but I am exhausted and cant
seem to find the answer. I have a query that I run from a command
button on a form. The query has three criteria set. The first is built
into the form and so is not a problem. Then the second and third
criteria prompt me for parameters. This all works fine and I get the
info I want broken down the way I want to see it. But sometimes I dont
want to filter at all on these two, and would like to see all of the
data. I have tried using all the wildcard options as in the halp files
but they are not working, seem to only relate to part strings. What
can I type into my parameter prompt to allow all records to show. Many
thanks.
Nov 13 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
Try "*", as the criteria value to show all records. Why not create a pop-up
form that will show your choices and use the form's several control values
as the criteria for your query?

Something like:
Like IIf([Forms]![myForm]![pickValue] Is
Null,"*",[forms]![myForm]![pickValue])

-Ed
"Lightning Tony" <ge*******@uk2.net> wrote in message
news:db**************************@posting.google.c om...
This is probably a really silly question but I am exhausted and cant
seem to find the answer. I have a query that I run from a command
button on a form. The query has three criteria set. The first is built
into the form and so is not a problem. Then the second and third
criteria prompt me for parameters. This all works fine and I get the
info I want broken down the way I want to see it. But sometimes I dont
want to filter at all on these two, and would like to see all of the
data. I have tried using all the wildcard options as in the halp files
but they are not working, seem to only relate to part strings. What
can I type into my parameter prompt to allow all records to show. Many
thanks.

Nov 13 '05 #2

P: n/a
ed's got it. you should just be able to just plug in a parameter like:

Like('*')

and have it retrieve all records for that field.

Ed Robichaud wrote:
Try "*", as the criteria value to show all records. Why not create a pop-up form that will show your choices and use the form's several control values as the criteria for your query?

Something like:
Like IIf([Forms]![myForm]![pickValue] Is
Null,"*",[forms]![myForm]![pickValue])

-Ed
"Lightning Tony" <ge*******@uk2.net> wrote in message
news:db**************************@posting.google.c om...
This is probably a really silly question but I am exhausted and cant seem to find the answer. I have a query that I run from a command
button on a form. The query has three criteria set. The first is built into the form and so is not a problem. Then the second and third
criteria prompt me for parameters. This all works fine and I get the info I want broken down the way I want to see it. But sometimes I dont want to filter at all on these two, and would like to see all of the data. I have tried using all the wildcard options as in the halp files but they are not working, seem to only relate to part strings. What
can I type into my parameter prompt to allow all records to show. Many thanks.


Nov 13 '05 #3

P: n/a


Hi gang
Thanks for the prompt reply. I have managed to achieve what I want by
adapting your ideas a little. Maybe I didn't explain that I am a
newcomer to VB so I didn't really understand the answer about popup
forms control values. What I did was type directly into the criteria row
of the underlying query as follows;

Like IIf([text] Is Null,"*",[text])

where text is a different message in each field that I am filtering on.
I don't understand it but it works so I am happy!Just for clarification
could I have found a way that doesn't require some kind of entry into
the query? When you say I should be able to just type "*" do you mean
directly into the parameter prompt box, because I had been trying just
about every combination and just kept getting blank queries (the column
headings display but no records). I have tried typing * on its own, in
quotation marks, in round brackets, in square brackets, with and without
quotation marks in brackets...all to no avail

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 13 '05 #4

P: n/a
What you've got shouldn't require any input: just hit Enter when the
parameter box appears, and you should get everything back.

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)

"Tony Harvey" <to***********@hotmail.com> wrote in message
news:41**********@127.0.0.1...


Hi gang
Thanks for the prompt reply. I have managed to achieve what I want by
adapting your ideas a little. Maybe I didn't explain that I am a
newcomer to VB so I didn't really understand the answer about popup
forms control values. What I did was type directly into the criteria row
of the underlying query as follows;

Like IIf([text] Is Null,"*",[text])

where text is a different message in each field that I am filtering on.
I don't understand it but it works so I am happy!Just for clarification
could I have found a way that doesn't require some kind of entry into
the query? When you say I should be able to just type "*" do you mean
directly into the parameter prompt box, because I had been trying just
about every combination and just kept getting blank queries (the column
headings display but no records). I have tried typing * on its own, in
quotation marks, in round brackets, in square brackets, with and without
quotation marks in brackets...all to no avail

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 13 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.