Results 1 to 7 of 7
  1. #1
    gremo is offline Novice
    Windows 10 Access 2016
    Join Date
    Aug 2016
    Posts
    4

    Calculations, Queries...must be a better way

    My database setup is this. It pulls the part number, costs, price etc from our ERP and allow (via a form) to fill in the Bill of Materials for the particular part. All of the components are based off of combo boxes which are based on queries from the inventory master table. The form I designed works fine, after it opens. What I am trying to do is pull the cost for each component, and calculate the cost of the component (Qty * Cost). Then total up the cost of the part.



    I have the calculations in a query. The work fine and calculate correctly. The problem is that It takes forever for the form to load and worse if I try to run the query with the calculations alone. I'm not talking about a few minutes, I'm talking 10 or 15 for it to initially run, if it runs at all.

    Any suggestions on how to set this up to run faster, or at least fast enough that we can use it.

  2. #2
    alansidman's Avatar
    alansidman is offline Indifferent
    Windows 10 Access 2013
    Join Date
    Apr 2010
    Location
    Steamboat Springs
    Posts
    2,536
    Have you run a compact and repair and see if that helps.

  3. #3
    gremo is offline Novice
    Windows 10 Access 2016
    Join Date
    Aug 2016
    Posts
    4
    I have, yes.

  4. #4
    gremo is offline Novice
    Windows 10 Access 2016
    Join Date
    Aug 2016
    Posts
    4
    I"m just trying to get the query to run so I can get the cost calculations for a spreadsheet.... It's been running 20 minutes.

  5. #5
    ssanfu is offline Master of Nothing
    Windows XP Access 2010 32bit
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    OK, how are you doing the calculations?
    Is it slow because of the number of records in the dB? Some of my reports were slow in a dB once the record in one table were over 1 million.... I don't remember when it started slowing down - it was a gradual process..

    Do you have a lot of DLookups in the query?

    What does is the SQL of the query?

  6. #6
    gremo is offline Novice
    Windows 10 Access 2016
    Join Date
    Aug 2016
    Posts
    4
    I don't have any dlookups. I have comboboxes based of separate queries for any values I need to look up. I only have 1489 records in the table the form is based on. Why would a form load, display the correct calculations from a query, but the query will not run... I waited over an hour and gave up.

  7. #7
    ssanfu is offline Master of Nothing
    Windows XP Access 2010 32bit
    Join Date
    Sep 2010
    Location
    Anchorage, Alaska, USA
    Posts
    9,664
    Would you post a pic of the relationship window?

    Again, what is the SQL of the query?

    Hard to help if we don't know how your dB id put together........

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

Similar Threads

  1. Query calculations off other queries
    By CT_AccessHelp in forum Queries
    Replies: 3
    Last Post: 03-14-2016, 10:14 AM
  2. Replies: 1
    Last Post: 08-29-2014, 04:15 PM
  3. Help with doing calculations in queries
    By DB88 in forum Access
    Replies: 3
    Last Post: 05-14-2014, 04:39 PM
  4. using calculations in queries
    By EWIG in forum Queries
    Replies: 3
    Last Post: 01-29-2014, 11:55 AM
  5. Replies: 1
    Last Post: 10-08-2012, 03:35 PM

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