Query to match XLS lookups (1 Viewer)

pickslides

Red Sails In The Sunset
Local time
Today, 17:17
Joined
Apr 29, 2008
Messages
76
Hi there, I have attached an XLS file I wish to replicate in Access using querie(s).

I seem to be losing to many records with my attempts.

The XLS sheet has 281 records when appending data using lookups and the Access Query only has 213 records.

MQ

My DB file was 2.3 MB so it couldn't be uploaded!
 

Attachments

  • 20151229 lookup.xls
    911.7 KB · Views: 90
  • 20151229.accdb
    812 KB · Views: 68
Last edited:

pickslides

Red Sails In The Sunset
Local time
Today, 17:17
Joined
Apr 29, 2008
Messages
76
Thx Paul, attached the DB in post #1

:)
 

pbaldy

Wino Moderator
Staff member
Local time
Today, 00:17
Joined
Aug 30, 2003
Messages
36,126
I get a warning on the spreadsheet so have not looked at it. In the db, it appears the timesheet table contains the 281 records you're looking for? I don't understand the data in the tables right off, but perhaps the query needs to be based primarily on the timesheet table?
 

pickslides

Red Sails In The Sunset
Local time
Today, 17:17
Joined
Apr 29, 2008
Messages
76
Yeh I have tried to link everything back to the TIMESHEET table with different types of joins and losing records
 

pbaldy

Wino Moderator
Staff member
Local time
Today, 00:17
Joined
Aug 30, 2003
Messages
36,126
Well, if you just queried that table you'd get all the records. I don't understand how the tables relate to each other, so can't offer a solution that includes the other tables. If they related directly to the timesheet table, you can edit the join to get all records from timesheet.
 

pickslides

Red Sails In The Sunset
Local time
Today, 17:17
Joined
Apr 29, 2008
Messages
76
It is true that TIMESHEET returns all 281 records but I want to append the following fields to this table

Append
Code:
catchment.display_text
Using the relationship
Code:
Catchment.entity_id = CASES.assignee_user_id
AND
Append
Code:
Subtype.display_text
Using the relationship
Code:
Subtype.entity_id = CASES.id
AND

ALSO needing to join
Code:
 Timesheet.description2 = CASES.reference_number
 

pbaldy

Wino Moderator
Staff member
Local time
Today, 00:17
Joined
Aug 30, 2003
Messages
36,126
The records in other tables would need a direct or indirect relationship to timesheet. Can you describe the nature of the data in the tables and how they relate to each other?
 

Users who are viewing this thread

Top Bottom