Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Data from two different tables to one

Status
Not open for further replies.

vise

Technical User
Jul 31, 2003
143
US
I am having trouble getting data from two different tables into one. They have one thing in common the "ID". I tried creating a relationship where there would be a left join.

Table 1 Has the data that needs to be shown always.

Table 2 has an the "ID" + other data that needs to be shown in same row as Table 1 when the query is run.

When I run the query I get a weird output where it list each record like 10 times and with different data for each record. help.. I've searched the forums but I don't need a union query as the tables aren't similar.
Thank you for your help.

-Vise
 
Now:

ID X Y Z
----------------
1 2 3 4
----------------
1 3 2 4
----------------
2 1 2 3
----------------
2 3 4 1


To show:

ID X Y Z
----------------
1 |2 3 4
-----------
|3 2 4
----------------
2 |1 2 3
-----------
|3 4 1
----------------

I figured out that there are actually mutliple records with the same ID in the second table. Is there a way to group the records so that when the ID is called up, that group shows up as shown above?


 
You can get records displayed like that in a report. You can't hide values in a query.

Duane MS Access MVP
[green]Ask a great question, get a great answer.[/green] [red]Ask a vague question, get a vague answer.[/red]
[green]Find out how to get great answers faq219-2884.[/green]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top