Results 1 to 8 of 8
  1. #1
    ajcollier93 is offline Novice
    Windows 10 Access 2016
    Join Date
    Mar 2018
    Posts
    4

    How do I make a query from a table within a table?

    How do I make a query from a table within a table?



    The first table is Products and the second is Inventory Levels. I want to select Product Name

    Attached Thumbnails Attached Thumbnails SQL.PNG  

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,652
    Looks like you missed a picture, and maybe some of the question. The short answer is you can't, and most of us never let users directly in tables anyway. They just see forms and reports.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    ajcollier93 is offline Novice
    Windows 10 Access 2016
    Join Date
    Mar 2018
    Posts
    4
    Are you not able to see the picture?

  4. #4
    ajcollier93 is offline Novice
    Windows 10 Access 2016
    Join Date
    Mar 2018
    Posts
    4
    So are you saying that I can not make any queries from this database. Its just a sample database I am using to train with

  5. #5
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,652
    I see one, it looks like another above it didn't work.

    No, I'm saying you can't have "a query from a table within a table", though in truth I'm not really sure what you're trying to accomplish.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  6. #6
    ajcollier93 is offline Novice
    Windows 10 Access 2016
    Join Date
    Mar 2018
    Posts
    4
    If you are seeing the correct picture, how would you go about making a query that selects ProductName?

    This is how I wrote it but it doesnt recognize the column. It just says enter parameter value.
    SELECT ProductName
    FROM Products;

  7. #7
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,652
    Like I said, in a table the short answer is you can't . The longer answer is you can using as lookup field, but most of us recommend not using those. Note number 2:

    http://www.theaccessweb.com/tencommandments.htm
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  8. #8
    isladogs's Avatar
    isladogs is offline Access MVP / VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    6,204
    I haven't used northwind for several years but it looks as though there is a space in the field name
    Try using
    Code:
    SELECT [Product Name] FROM Products;
    Colin Riddington, Access MVP, Website, email
    The more I learn, the more I know I don't know. When I know I don't know, I keep quiet!

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

Similar Threads

  1. Replies: 2
    Last Post: 08-12-2016, 07:00 AM
  2. Replies: 2
    Last Post: 02-17-2015, 01:01 PM
  3. Replies: 1
    Last Post: 03-11-2014, 11:30 AM
  4. Make Table Query
    By Lpitt56 in forum Access
    Replies: 3
    Last Post: 08-18-2011, 12:27 PM
  5. Replies: 2
    Last Post: 10-27-2009, 07:09 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