Results 1 to 8 of 8
  1. #1
    Athar Khan is offline Advanced Beginner
    Windows 7 32bit Access 2013 32bit
    Join Date
    Mar 2017
    Posts
    63

    Display All Records Even If A Row In Child Table Is Empty


    Hello, this is my first post here. I created a query which displays unique records from Orders table using OrderID (which is foreign key in Order Details table) BUT the problem is that this query can not retrieve all records from Order table. If any row in Order Details is empty (OrderDetails.OrderID = Null) , then the query can not display that specific record in parent table (Orders). Please help

  2. #2
    Bulzie is online now VIP
    Windows 7 64bit Access 2007
    Join Date
    Nov 2015
    Posts
    1,471
    Do a left join between the tables on the OrderID field(arrow going from Order to OrderDetail table.

  3. #3
    Athar Khan is offline Advanced Beginner
    Windows 7 32bit Access 2013 32bit
    Join Date
    Mar 2017
    Posts
    63
    Thanks for a quick response. If you are talking about relationship, I think it has already a one-to-many relationship with Order Details

  4. #4
    Bulzie is online now VIP
    Windows 7 64bit Access 2007
    Join Date
    Nov 2015
    Posts
    1,471
    No not relationship. In your query where you link the 2 tables, double click on the line between the 2 tables and choose the option to return all records from Orders and only those from OrderDetail where they match.

  5. #5
    Athar Khan is offline Advanced Beginner
    Windows 7 32bit Access 2013 32bit
    Join Date
    Mar 2017
    Posts
    63
    Ok, let me try

  6. #6
    Athar Khan is offline Advanced Beginner
    Windows 7 32bit Access 2013 32bit
    Join Date
    Mar 2017
    Posts
    63
    Thank you very much. It is solved

  7. #7
    Athar Khan is offline Advanced Beginner
    Windows 7 32bit Access 2013 32bit
    Join Date
    Mar 2017
    Posts
    63
    Please let me know how can I mark this question as Solved, how can I thank you with an icon or how can I give you star 🌟

  8. #8
    Bulzie is online now VIP
    Windows 7 64bit Access 2007
    Join Date
    Nov 2015
    Posts
    1,471
    No need, glad to help. I will mark the thread Resolved for you.

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

Similar Threads

  1. empty a table/delete all records
    By Jen0dorf in forum Access
    Replies: 3
    Last Post: 02-22-2016, 02:53 PM
  2. Filtering Master Records and Subform Child Records
    By Nerther in forum Programming
    Replies: 6
    Last Post: 10-01-2013, 05:24 PM
  3. Child Record Created, but won't display in child form
    By CementCarver in forum Programming
    Replies: 1
    Last Post: 04-10-2013, 12:42 PM
  4. Replies: 5
    Last Post: 03-23-2012, 11:40 AM
  5. Replies: 12
    Last Post: 08-30-2011, 03:36 PM

Tags for this Thread

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