Query Definitions

Bernhard Zweifel 41 Reputation points
2021-08-27T07:24:13.013+00:00

Hi,

I have a table with the field Year. Whenever I pull this field into a query, save the query and reopen it or refer to it the query has changed Year to Expression1: tablename.Jahr.
Therefore all Forms and Records based on the query give no result.
Perhaps changing Year something else would fix the problem but I hesitate to do that because it would mean to search for and change all the queries, forms and Report that use this table.
Any suggestions?
Thanks boz

Access Development
Access Development
Access: A family of Microsoft relational database management systems designed for ease of use.Development: The process of researching, productizing, and refining new or existing technologies.
859 questions
0 comments No comments
{count} votes

Accepted answer
  1. Karl Donaubauer 1,726 Reputation points MVP
    2021-08-27T11:39:56.307+00:00

    Hi,

    I suggest changing the name anyway, because Year is the name of a built-in function in Access (which returns the year of a date).

    If the name is used in really a lot of places, I would use a find and replace tool. The current standard for this is https://accessdevtools.com/product/find-and-replace/.

    Servus
    Karl


    http://AccessDevCon.com
    https://www.donkarl.com


1 additional answer

Sort by: Most helpful
  1. Karl Donaubauer 1,726 Reputation points MVP
    2021-08-30T12:39:52.48+00:00

    Hi,

    For the add-in have a look if the first FAQ on their support page helps.

    When I want to open the Form I get a message that Access cannot find tablename.Jahr.

    Is it an (error) message with an error number or is it a parameter window that asks for your input?

    The old field name could still be in many places like a sorting or filtering expression/property of the form etc.

    Did you check that the query opens without problem?

    Servus
    Karl


    http://AccessDevCon.com
    https://www.donkarl.com

    0 comments No comments