I need a query to select between 2 choices.

Jeanette

Registered User.
Local time
Today, 02:43
Joined
Dec 17, 2001
Messages
52
Please help! I have a many to many table with three fields: Owner, ProjectName, Ownertype. The ownertype field can have four choices: Sponsor, Owner/Contractor, Owner, or Contractor. The problem is if ProjectName has both an owner and owner/contractor or two owners in the ownertype field is the a way to choose one owner and not have the records repeat for both owners. I hope I am not to confusing. I really need help with this problem. Thanks in advance.
 
I tried grouping the query it still repeats the records if there is owner and owner/contractor. Grouping does not help me pick which record I want when there are two owners for one record.
 
Either eliminate Owner and OwnerType from the totals query if you only want a distinct list of Projects or rather than "Group By" use "First" to select the first value for both of those fields.
 
I don't think I explained my problem clearly. I have one field (Ownertype) with four different choices:They are Sponsor,Owner/Contractor,Owner or Contractor. If at all possible, I want a query that can choose one owner when there are two owners per record. Right now if I create a query with "Owner" or "Owner/Contractor" in criteira for Ownertype field I have repeated records if there are two owners or an owner and an owner/contractor. Either I am not clear on how to use the "Group By" as you explained it or it is not right for my problem. I tried using the "Group By" as you explained. I still get repeated records. I think I should mention another field which has the names of different owners will always cause the records to repeat in a "Group By" query. Maybe there is no answer to my problem. :confused:
 
OK!! I sort of got the query to work by using "Group by" and "First". The query gives me one record when there are two owners, but it does not always give me the owner of my choice. How do I get the query to pick the owner I want.:confused:
 

Users who are viewing this thread

Back
Top Bottom