Ask Experts Questions for FREE Help !
Ask
    Feprincess's Avatar
    Feprincess Posts: 17, Reputation: 4
    New Member
     
    #1

    Apr 20, 2007, 12:55 PM
    Calculating Fields
    I'm setting up a Query in Design View and I need to find out the price per unit.
    I need to mulitply two fields, Amount and Quantity with the Answer in the Amount Field. What wording should I use?
    The two fields are from two different Tables.
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #2

    Apr 20, 2007, 01:02 PM
    This doesn't quite make sense. Generally you would be dealing with 2 tables here; Product and OrderDetails. They would look like this:

    TblProduct
    ProductID
    Product
    UnitPrice

    TblOrderDetails
    OrderDetailID
    ProductID
    Quantity

    You would then calculate the extended price in your query using a column like:

    ExtPrice: tblOrderDetails.Quantity * tblProduct.UnitPrice

    However, it would be better to store the UnitPrice in the Detail record so, when the price changes the Detail record will reflect the price at time of order.
    Depressed in MO's Avatar
    Depressed in MO Posts: 571, Reputation: 94
    Senior Member
     
    #3

    Apr 20, 2007, 01:32 PM
    Quote Originally Posted by ScottGem
    This doesn't quite make sense. Generally you would be dealing with 2 tables here; Product and OrderDetails. They would look like this:

    tblProduct
    ProductID
    Product
    UnitPrice

    tblOrderDetails
    OrderDetailID
    ProductID
    Quantity

    You would then calculate the extended price in your query using a column like:

    ExtPrice: tblOrderDetails.Quantity * tblProduct.UnitPrice

    However, it would be better to store the UnitPrice in the Detail record so, when the price changes the Detail record will reflect the price at time of order.
    Wouldn't she have to match a field between these two tables, such as Product ID (for ex.)?
    ScottGem's Avatar
    ScottGem Posts: 64,966, Reputation: 6056
    Computer Expert and Renaissance Man
     
    #4

    Apr 20, 2007, 05:37 PM
    Yes. She would need to create a join between the ProductID fields.
    Feprincess's Avatar
    Feprincess Posts: 17, Reputation: 4
    New Member
     
    #5

    Apr 21, 2007, 11:22 AM
    I created a field called 'Total' and used an equation like this.
    [Amount]*[Quatntitiy] it worked this way.
    I was trying to run the calculation in the criteria row.
    Obviously, I learning Access right now. I'm talking an online class, so when I run into a problem I have to go to the internet.
    Thanks for your help.

Not your question? Ask your question View similar questions

 

Question Tools Search this Question
Search this Question:

Advanced Search

Add your answer here.


Check out some similar questions!

Garden Fence over septic fields? [ 1 Answers ]

I would like to put a raised bed vegetable garden on top of my septic fields. It will need a fence as it is on a deer and woodchuck highway. Can I build a fence over my septic fields without ruining them:confused:

Cascading lookup fields... [ 3 Answers ]

Want to use the form frmCardDetails to populate tblCards. Want to select the sport from a lookup field linked to tblSports and then the League from tblLeagues, BUT only displaying the leagues that are included in that sport. I have looked at http://support.microsoft.com/kb/209595/en-us and...

Maple tree roots and septic fields [ 1 Answers ]

My home is in a new sub and the association has planted a maple tree in the peninsula between the side walk and street. The concern I have is that my septic field is about fifteen feet away from where the tree is. How deep do the roots grow? Should I take this tree out and plant a different type of...


View more questions Search