Page 1 of 2 12 LastLast
Results 1 to 15 of 22
  1. #1
    kwooten is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Jun 2011
    Posts
    255

    Where


    How does a "WHERE" work? I have a Name list in one table and a Name list in another table and only want the records where the 2 names are equal.

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,917
    Have you tried to use the built in Query Builder yet?

  3. #3
    kwooten is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Jun 2011
    Posts
    255
    No.. I'll give it a shot

  4. #4
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,917
    Post back here if you still need assistance as there are dozens of helpers here that can assist.

  5. #5
    kwooten is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Jun 2011
    Posts
    255
    That didnt work... I have a table (table 1) with the person ID and Created User. I have to get their advisor which is in another table (table 2) by SSN so I link table 2 to another table (table 3) to get the name of advisor. Then in table 4 is link the Created User from table 1 to table 4 to get the created name. I need only the records where the advisor = the created name.

  6. #6
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,917
    Why are you looking for a name instead of an ID Number?

  7. #7
    kwooten is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Jun 2011
    Posts
    255
    Cause I have to build a report that shows the number of contacts by name.

  8. #8
    kwooten is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Jun 2011
    Posts
    255
    I have seemed to have made the habit of making Access harder than it is so I am open to suggestions.

  9. #9
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,917
    You can set up a relationship for your tables based on the ID's of the people. Then when you include both tables in a query, all of the fields of both tables are available as if they were in one table.

  10. #10
    kwooten is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Jun 2011
    Posts
    255
    Initially that was sort of what I did but had one query with the person data, then in a new query built in the advisor. I had it done yesterday and it was running right. I got in this morning and it was all messed up and i dont know what i originally did.

  11. #11
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,917
    I usually start over when that happens. I'm sure you will do it better the second time.

  12. #12
    kwooten is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Jun 2011
    Posts
    255
    right now, I have one table that has my employees and their advisors along with the user id of the creator of the record. Now I can get the user name of the creator but i cant get it to only show me the records where the User and Advisor are the same.

    Really what this system does is tracks how many calls have been made. The reason for the creator is because someone other than that employees advisor can call them, but I only care about how may employees in the advisors "portfolio of employees" was contacted by the assigned advisor.

  13. #13
    kwooten is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Jun 2011
    Posts
    255
    I know I had the first file showing the data based on a join but i cant seem to get it figured out again.

  14. #14
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,917
    It sounds like you need to make a query with 2 copies of that table.

  15. #15
    kwooten is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Jun 2011
    Posts
    255
    I included the contacted employees id and it gave me more records. Its still not right though.. Why would including another field increase the number of records?

Page 1 of 2 12 LastLast
Please reply to this thread with any new information or opinions.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums