MS Access 2007 JOIN on several fields

I have two tables similar to the following:

enter image description here

enter image description here

I am trying to create a query in Access to create a table as follows:

enter image description here

The bottom line is that the JOIN must match the Date and Name fields. I can join the fields from T2 to T1.

What is the correct syntax (either in SQL or through the query constructor) for combining fields in Date and Name?

My attempts duplicate the number of fields.

+5
source share
2 answers

Using the query design window, drag Date from T1 according to Date to T2 and similarly drag the name from T1 to T2. This will give you an INNER JOIN by the name and date of the biota. Switch to SQL view to view SQL.

, . , , , - MS Access, , ().

+5

sql

Select T1.Name, T1.Date,T1.Alpha, T2.Beta
From T1
Inner Join T2 On T1.Name = T2.Name and T1.Date = T2.Date

...

+1

All Articles