Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

List From Two Tables

Posted on 2007-12-02
5
Medium Priority
?
179 Views
Last Modified: 2010-03-20
I have two tables, a Manager table and a Employee table and I want to make a report that will List each managers name and underneath that list every employee related to this manager.
0
Comment
Question by:cursive34
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 75
ID: 20391834
Create a Select query joining the MgrID in the Manager table to the MgrID in the Employee table and make this the recordsource for the report.

Then in the report, Group by Manager and list each employee name.

mx
0
 
LVL 75

Accepted Solution

by:
DatabaseMX (Joe Anderson - Microsoft MVP, Access and Data Platform) earned 2000 total points
ID: 20391842
Your SQL for the query should look something like this:

SELECT tblMgr.MgrName, tblEmp.EmpName
FROM tblMgr INNER JOIN tblEmp ON tblMgr.MgrID = tblEmp.MgrID;

mx
0
 
LVL 2

Author Comment

by:cursive34
ID: 20391886
I have the report set up in the Grouping/Sorting as this:

tblMgf.MgfName in the Field and Sort Ascending.

and i have the tblMgr.MgrName and tblEmp.EmpName as fields on the report. it will list everything in order but keep repeating the mgrname
0
 
LVL 2

Author Comment

by:cursive34
ID: 20391895
I got it set straight i forgot to add the group header thanks so much
0
 
LVL 75
ID: 20391900
You are most welcome.  

mx
0

Featured Post

Learn how to optimize MySQL for your business need

With the increasing importance of apps & networks in both business & personal interconnections, perfor. has become one of the key metrics of successful communication. This ebook is a hands-on business-case-driven guide to understanding MySQL query parameter tuning & database perf

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This post looks at MongoDB and MySQL, and covers high-level MongoDB strengths, weaknesses, features, and uses from the perspective of an SQL user.
Instead of error trapping or hard-coding for non-updateable fields when using QODBC, let VBA automatically disable them when forms open. This way, users can view but not change the data. Part 1 explained how to use schema tables to do this. Part 2 h…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question