Unmatched Records issue

A

Annemarie

I'm trying to list records that appear in one table, but not the other. I'm
using the Unmatched Records option and all is well, except it's adding
records that DO appear in both tables. here's a basic setup of my tables (* =
primary key):
agent_list_table:
Agent_ID
Department
First_Name
Last_Name
*Username
Role
Email

login_table:
*ID
Department
First_Name
Last_Name
Username
Login_Time
Logout_Time
Hours_Online

I'm comparing the two tables by Username. I want to display records that
appear in the agent_list_table and NOT anywhere in the login_table.
Yes the usernames are entered identically in both tables.
No the username will not display more than once in the agent_list_table.

Basically, I'm trying to find people who didn't log in.
 
K

KARL DEWEY

Post the SQL of your unmatched query. Open query in design view, click on
VIEW - SQL View, highlight all, copy,, and paste in a post.
 
A

Annemarie

SELECT agent_list_table.Department, agent_list_table.First_Name,
agent_list_table.Last_Name, agent_list_table.Username, agent_list_table.Role
FROM agent_list_table LEFT JOIN login_table ON agent_list_table.Username =
login_table.Username
WHERE (((login_table.Username) Is Null));
 
K

KARL DEWEY

Use this WHERE ---
WHERE login_table.Username Is Null OR login_table.Username ="";
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top