Results 1 to 4 of 4
  1. #1
    dundee is offline Novice
    Windows 8 Access 2013
    Join Date
    Jul 2015
    Posts
    1

    insert data from another table

    Hi,
    Im new hier and new in Access. Lot of Excel done so far but only some Access.
    Im sure it is a trivial for you but...


    I have two tabels: [Orders] and [Items].
    In table [Orders] column [ItemsName] is with relation to table [Items], so I can choose item and get the name of item in table [Orders].
    Now the question: how to get in table [Orders] in column [Price] the price from tabel [Item] for that item?

    Thx in advance

  2. #2
    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,849

  3. #3
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,549
    you should have a table of tInventory, in it is
    tInventory
    [item]
    [price]

    when the user picks the ITEM, you run an update query, that joins tOrderDetail to tInventory on [item], to update tOrderDetail.[price] from tInventory .[price]

  4. #4
    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,849
    For more info on what ranman256 is saying see this video. In overview, you record the AgreedtoPrice or OrderDetailPrice in the orderDetail record so that you
    -could regenerate an old order,
    -do not potentially change the price on all previous orders

    see https://www.accessforums.net/queries...tml#post205278 for other info.

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

Similar Threads

  1. Replies: 1
    Last Post: 06-12-2015, 02:02 PM
  2. Replies: 5
    Last Post: 12-01-2014, 11:31 AM
  3. Insert Data from one table to another Query
    By zipaway in forum Queries
    Replies: 3
    Last Post: 07-28-2014, 10:15 AM
  4. Replies: 25
    Last Post: 01-29-2013, 08:49 AM
  5. Replies: 1
    Last Post: 12-28-2010, 11:24 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