none
Parameter query pops up, but I have no parameter whatsoever RRS feed

  • Question

  • I'm sorry if this is a dumb question.  I've been using Access for around 15 years or so.  I know it pretty well, but I definitely don't use it every day.  Now, I am actually using it, and I have this really, really, really weird thing happening.  I'm trying to run a simple query, and I keep getting prompted to enter a parameter.  That would be fine, but I have no parameter whatsoever in my query.  Not only that, but one of the underlying queries that feeds into this query works perfectly well, but when I use the preliminary query in my summary query, everything is turned to nulls, even though the preliminary query returns the correct results.  And, of course, I'm prompted to enter a parameter......and there are no parameters in any of my queries.

    I can't share the SQL here, because it's classified information.  Basically, I was just hoping someone could offer some insight as to what to try, or how to troubleshoot this thing.  I'm completely baffled, but I've been working on this for around 16 hours straight, so that may be part of the problem.

    Anyway, I'd welcome any thoughts/ideas/consolation.

    Thanks.


    Knowledge is the only thing that I can give you, and still retain, and we are both better off for it.

    Thursday, July 23, 2015 2:57 AM

Answers

  • Thanks everyone.  As it turns out, I didn't have the table in the Design View when I ran the query.  When I dragged the table over, and joined it to my mapping table, the problem went away.

    So dumb.  That's what I get for working 16 hours straight!!!

    Thanks again for trying to help me.


    Knowledge is the only thing that I can give you, and still retain, and we are both better off for it.

    Thursday, July 23, 2015 2:35 PM

All replies

  • Well you're getting a parameter request because something in one of your queries isn't recognized as a valid field name or value.  However, without seeing your SQL, we can't help you identify what the problem really is.
    Thursday, July 23, 2015 3:33 AM
  • You don’t mention if the tables are linked to say a back end accDB, or that of SQL server.

    If you using some kind of linked tables, then often if you change or re-link the tables to another database that has a DIFFERENT structure, then a simple run of that query will cause a query prompt.

    And a query that by intention (or accident) was modified in which a column name was changed will ALSO cause a prompt for that non-existing column. (so a change in the table structure, or table columns names **OR** any modification in the query that changes a column name) will cause a prompt when the query is run.

    I would thus consider re-building the queries using the query builder. This ensures that your column names are correct and if you find such quires now work, then I would compare them against the non-working queries in SQL view (work on a copy of course!!!).

    As others pointed out, without any table structures, or SQL query info posted here, then any suggestions we give really amount to throwing darts in a room without the lights on.

    However, best bests are the query was modified and a non-existing column name resides in the query. Or the query was not changed, but the table structure was changed and thus again a non-existing column exists in the query.

    So any non-existing column in the query will cause a parameter prompt - how the non existing column comes to be as noted can occur several ways and the query does not necessary have to been changed - it could the table structure was changed.

    Regards,
    Albert D. Kallal (Access MVP)
    Edmonton, Alberta Canad

    Thursday, July 23, 2015 4:53 AM
  • IMHO the type of BE makes no difference. I always debug this the same way:

    In my code that runs the query, I set a breakpoint.
    Once it hits that, I hit Ctrl+G to reveal the Immediate window where I type:
    ?myQuerydef.Parameters.Count
    1

    ?myQuerydef.Parameters(0).Name
    Forms!myForm!myControl

    (of course yourObjectNames will be different from mine)


    -Tom. Microsoft Access MVP

    Thursday, July 23, 2015 5:00 AM
  • Thanks everyone.  As it turns out, I didn't have the table in the Design View when I ran the query.  When I dragged the table over, and joined it to my mapping table, the problem went away.

    So dumb.  That's what I get for working 16 hours straight!!!

    Thanks again for trying to help me.


    Knowledge is the only thing that I can give you, and still retain, and we are both better off for it.

    Thursday, July 23, 2015 2:35 PM