Results 1 to 3 of 3
  1. #1
    AccessNoobie is offline Novice
    Windows 11 Access 2007
    Join Date
    Jul 2022
    Posts
    1

    Query Repeats Data for Each Variable Creating Massive Query - How to Define Query

    Hey,

    I am new to Access and I have come across an issue where I am struggling prevent massive duplications of data. I am switching an unstable database from excel to Access and have pulled the data. However, I have found that my variables all repeat across from each other creating a huge query. Yet my data is specific to a Month & Year - for example in the original excel file I can filter for 01-Jun-22 and there a line of data with each variable and the specific forecast.

    When I create the query linking in other variables it duplicates all variables creating a query of over 160,000 rows of data. Even after placing criteria constraints, I am still left with 1,000s of lines of data that are incorrect when I just need to duplicate the data from my original excel file.



    Any advice or topic would be helpful, I just need a general direction to steer.

    Thanks

  2. #2
    Join Date
    Jan 2017
    Location
    Swansea,South Wales,UK
    Posts
    4,910
    Without seeing the tables or query, we would just all be guessing.
    I'll make mine. You have not normalized your db, just copied the excel layout. However as mentioned, just a guess.
    Please use # icon on toolbar when posting code snippets.
    Cross Posting: https://www.excelguru.ca/content.php?184
    Debugging Access: https://www.youtube.com/results?sear...bug+access+vba

  3. #3
    Micron is offline Virtually Inert Person
    Windows 10 Access 2016
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,784
    Agree with that, although I suspect the main problem is a query with no joins. Then you have a Cartesian query and if there are 100 records in 4 tables, you'll likely get 100,000,000 records. The only way you could narrow that down with criteria is to use limited queries instead of tables, but the number of returned records will still be more than what you expect. In addition, if WGM is correct, it is likely that you cannot make joins even if you want to.
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Define data type when creating a table based on a query
    By viniciusfmnogueira in forum Access
    Replies: 3
    Last Post: 10-31-2019, 09:38 AM
  2. Replies: 4
    Last Post: 01-14-2016, 12:51 PM
  3. Pre-Define query based on input data
    By twildt in forum Access
    Replies: 1
    Last Post: 04-21-2014, 08:36 AM
  4. Replies: 1
    Last Post: 03-07-2013, 03:21 PM
  5. having to deal with massive query's
    By quandore in forum Access
    Replies: 1
    Last Post: 01-11-2012, 08:34 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums