Results 1 to 5 of 5
  1. #1
    2 Star Lounger
    Join Date
    Jun 2001
    Posts
    146
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Invalid query names (Access 2000 SR-1)

    I've started getting the following error message with my Query names:

    " 'Query name' is not a valid name. Make sure that it does not include invalid characters or punctuation and that it is not too long."

    Strangely, this message pops up after I've already saved the Query under the now invalid name. I've tried changing the name to a single letter or a default name like Query1, but the error message persists.

    Thanks,
    Bob

  2. #2
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Invalid query names (Access 2000 SR-1)

    Give us an example of the query names that have prompted this message. And post a sample of the SQL for one of these queries.
    Charlotte

  3. #3
    2 Star Lounger
    Join Date
    Jun 2001
    Posts
    146
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Invalid query names (Access 2000 SR-1)

    Here are two:

    *********************

    Name (First query): Archive Selected Records

    SQL (First query):

    INSERT INTO [CorrectionCRs Archive]
    SELECT CorrectionCRs.*
    FROM CorrectionCRs
    WHERE (((CorrectionCRs.CorrDate) Between [Starting archive date.] And [Ending archive date.]))

    Name (Second query): Delete Selected Records

    SQL (Second query):

    DELETE CorrectionCRs.*, CorrectionCRs.CorrDate
    FROM CorrectionCRs
    WHERE (((CorrectionCRs.CorrDate) Between [Starting deletion date.] And [Ending deletion date.]));

    *********************

    The queries do work at the beginning, but if, for example, I make a small change in the wording of a parameter query, the error message starts appearing.

    Thanks,
    Bob

  4. #4
    Bronze Lounger
    Join Date
    Nov 2001
    Location
    Arlington, Virginia, USA
    Posts
    1,394
    Thanks
    0
    Thanked 3 Times in 3 Posts

    Re: Invalid query names (Access 2000 SR-1)

    That's an odd error you're getting - there's nothing "invalid" about the query names you're using (not too long, no illegal characters, etc). By any chance do you have the Name AutoCorrect feature enabled? This so-called "feature" is responsible for all sorts of wierd errors. See this MSKB article:

    Name AutoCorrect Does Not Repair Query Field/Table Names

    One possible cause for errors is cited as: "The query is an action query, such as an update or append query, and the field that was changed is in an output column."

    I don't know if this applies to your problem, but may be worth checking out. If you are using Name AutoCorrect, I'd strongly recommend turning it off, although SR-1 supposedly fixed some of these problems. Otherwise have no clue on reason for error.

    HTH

  5. #5
    New Lounger
    Join Date
    Nov 2001
    Location
    Hokitika, West Coast, New Zealand
    Posts
    21
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Invalid query names (Access 2000 SR-1)

    From the example you posted it appears you have spaces in the query name. If that is so, I think you would need either [ ] or " " around the name.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •