If I understand your question, you are using a parameter query that refers
to a control on a form for its parameters. I don't use parameter queries in
this situation, but construct the where clause and append it to the basic
SQL which I use for the RecordSource of a Report or Form (or for the
WhereCondition parameter of a DoCmd.OpenForm or DoCmd.OpenReport). The only
kind of Query that I would execute directly in such a case would be an
Action Query -- Make Table, Append, Update, or Delete. In developed
applications, my users access the information via Forms and Reports and do
not have direct access to Tables or Queries in Datasheet view.
If you _are_, as I do, building the WhereCondition or the WHERE clause, I
find it useful to either use Debug.Print to view the constructed string in
the Immediate Window, or display it in a MsgBox after I have built it. If
you are using the Query that internally refers to the Controls, you cannot
"intercept" the SQL to examine it in these ways.
Access 2000 is out of support and has long been plagued with "issues", not
all of which are resolved even with all three Service Releases / Service
Packs. But, if you cannot upgrade to Access 2002 or 2003, be sure to obtain
and apply all the SR/SPs and any more recent fixes... they can be obtained
through the Office Update menu item in Windows Update (useful, generally,
only if you have a high-speed Internet connection).
Larry Linson
Microsoft Access MVP
"pete moss" <mo********@yahoo.com> wrote in message
news:8f**************************@posting.google.c om...
I finally tried got around to converting an old access 2.0 databases
to Access 2000
(these are backend front end databased with the back end tables still
in 2.0)
Most everything seems to work O.K except one parameter select query
which gets its parameters from a form.
It's a search query that's front ended by a form with unbound text
boxes
A user is prompted to enter a combination of text and leading and/or
trailing asterisk's into the form's text box and press a button which
opens the query.
The clerks will typically enter the * as a wildcard - in the acess 2.0
version irt works fine in the 2000 version ---blank dynaset.
I attempted to troubleshoot by accessing the query directly and
entering the parameter in the QBE grid- it works fine with any
combination of text and *
Next I tried troubleshooting the form that provides the paramenter to
the query.
If I type the exact text I'm looking for it works fine but any
incomplete test plus asterisk, asteric by itself, or % sign returns a
blank dynaset.
Somehow whe the parameter in the form's tesxt box is not getting to
the query properly
Any Ideas
Pete Moss