Results 1 to 7 of 7
  1. #1
    ShadeRF is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Posts
    24

    Query Formulas


    I need to do the following on a query. I have a field we'll call Cost1 that I divide by .77 divide by field PackSize. I have another field called ReqPrice. I want to take the result of the first formula and subtract it from ReqPrice. If there is a difference, in other words, it doesn't equal 0 I want to output what number would need to be added/subtracted to the first formula so my 2nd formula equals 0. I hope that makes sense. Thanks!

  2. #2
    alansidman's Avatar
    alansidman is offline VIP
    Windows 7 32bit Access 2007
    Join Date
    Apr 2010
    Location
    Steamboat Springs
    Posts
    2,529
    This might be easier to understand if you showed some sample data with field names and what the end result should look like.

  3. #3
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,725
    I agree with Alan. This doesn't make sense
    Cost1 that I divide by .77 divide by field PackSize

  4. #4
    ShadeRF is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Posts
    24
    OK.

    Fields:

    LIC, PackSize, Retail - Let's assign 90 to LIC, 12 to Packsize, and 8.99 to Retail

    Query:

    SPACalc1: (([LICDistributor])/0.77)/([PackSize]) = 9.74
    SPACalc2: ([SPACalc1])-([Retail]) = .75

    Since SPACalc2 didn't equal 0, I want to find out what # to add/subtract to LICDistributor in the first formula so that the second formula will equal 0. Hopefully this clears it up

  5. #5
    hertfordkc is offline 18 year novice
    Windows XP Access 2007
    Join Date
    Mar 2011
    Posts
    481
    X = Retail * Packsize * 0.77 - LicDist

  6. #6
    ShadeRF is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Posts
    24
    I neglected one peice of info on the formula. How would I adjust this in to fit your formula you gave me?

    SPACalc1: (([LICDistributor])/0.77)/([PackSize])*1.30 = 12.66
    SPACalc2: ([SPACalc1])-([Retail]) = 3.67

    Still need to solve
    LICDist-X/.77/PackSize*1.30=Retail(8.99)

  7. #7
    hertfordkc is offline 18 year novice
    Windows XP Access 2007
    Join Date
    Mar 2011
    Posts
    481

    Try this

    Quote Originally Posted by ShadeRF View Post
    I neglected one peice of info on the formula. How would I adjust this in to fit your formula you gave me?

    SPACalc1: (([LICDistributor])/0.77)/([PackSize])*1.30 = 12.66
    SPACalc2: ([SPACalc1])-([Retail]) = 3.67

    Still need to solve
    LICDist-X/.77/PackSize*1.30=Retail(8.99)
    -----------------------------------------------------------------------------------------------------------------------------
    x = Retail * Packsize * .77 / 1.30 - LICDist

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

Similar Threads

  1. Formulas
    By dunnmel4 in forum Access
    Replies: 0
    Last Post: 03-27-2011, 04:59 PM
  2. Replies: 21
    Last Post: 12-29-2010, 01:30 PM
  3. Formatting formulas
    By katrinanyc926 in forum Queries
    Replies: 2
    Last Post: 08-16-2010, 07:52 AM
  4. Replies: 1
    Last Post: 01-22-2008, 03:36 PM
  5. Replies: 0
    Last Post: 03-05-2007, 08:04 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