Results 1 to 3 of 3
  1. #1
    Join Date
    Dec 2009
    Posts
    2

    Red face Unanswered: Access Update table by a Join

    I've been a while since I used Access, I'm trying to write a update join
    query,I've followed examples from here and the web, but Access throws a error
    "use an updatable query". Can someone help?

    Thanks

    Some Methods that I tried...

    UPDATE DISTINCTROW tbl_PreviousStockOut
    INNER JOIN Qry_Stockout_Summary
    ON tbl_PreviousStockOut.CategoryName = Qry_Stockout_Summary.ReportingGroup
    SET Qry_Stockout_Summary.Today = tbl_PreviousStockOut.Previous;

    UPDATE tbl_PreviousStockOut
    INNER JOIN Qry_Stockout_Summary
    ON Qry_Stockout_Summary.ReportingGroup = tbl_PreviousStockOut.CategoryName
    SET tblPreviousStockOut.Previous = Qry_Stockout_Summary.TODAY

    UPDATE tbl_PreviousStockOut
    SET tbl_PreviousStockOut.Previous = (SELECT Qry_Stockout_Summary.TODAY FROM
    Qry_Stockout_Summary WHERE Qry_Stockout_Summary.ReportingGroup =
    tbl_PreviousStockOut.CategoryName)
    WHERE EXISTS (SELECT Qry_Stockout_Summary.TODAY FROM Qry_Stockout_Summary
    WHERE Qry_Stockout_Summary.ReportingGroup = tbl_PreviousStockOut.CategoryName)

  2. #2
    Join Date
    Feb 2004
    Location
    New Zealand
    Posts
    1,423
    Provided Answers: 8
    Why not break it down into its steps

    1 step create the Join Query ( get it working)

    2 step do the Update query base on the Join Query
    hope this help

    See clear as mud


    StePhan McKillen
    the aim is store once, not store multiple times
    Remember... Optimize 'til you die!
    Progaming environment:
    Access based on my own environment: DAO3.6/A97/A2000/A2003/A2007/A2010
    VB based on my own environment: vb6 sp5
    ASP based on my own environment: 5.6
    VB-NET based on my own environment started 2007
    SQL-2005 based on my own environment started 2008
    MYLE
    YOUR PASSWORD IS JUST LIKE YOUR TOOTHBRUSH DON'T SHARE IT.

  3. #3
    Join Date
    Dec 2009
    Posts
    2
    Thanks, and that's what I tried, using a simple test table/query update. Taking that syntax and using it in this query give's me that error, which is making me wonder why it's throwing that error on that table.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •