G
Guest
Hello, I have an invoice table that includes the fields CustomerNumber and
DivisionNumber. Customers can deal with multiple divisions.
CustomerNumber DivisionNumber
ABC Co 10
ABC Co 10
ABC Co 10
Smith Inc 10
Smith Inc 10
Jones Corp 20
Jones Corp 20
Jones Corp 10
XYZ Inc 20
XYZ Inc 20
I am trying to come up with a query that will identify that Jones Corp has
records in both division 20 and 10. I would like the results to like the
below.
CustomerNumber DivisionNumber
Jones Corp 20
Jones Corp 10
I know that I can first do a select query that groups on the customernumber
and divisionnumber fields. AND, then do a find duplicates query on that
first query for records with duplicate customer numbers.
However, I am trying to see if I can do this with just one query (possibly
using select queries or something).
Does anyone know if this is possible using just one select query???
Thanks,
Bill
DivisionNumber. Customers can deal with multiple divisions.
CustomerNumber DivisionNumber
ABC Co 10
ABC Co 10
ABC Co 10
Smith Inc 10
Smith Inc 10
Jones Corp 20
Jones Corp 20
Jones Corp 10
XYZ Inc 20
XYZ Inc 20
I am trying to come up with a query that will identify that Jones Corp has
records in both division 20 and 10. I would like the results to like the
below.
CustomerNumber DivisionNumber
Jones Corp 20
Jones Corp 10
I know that I can first do a select query that groups on the customernumber
and divisionnumber fields. AND, then do a find duplicates query on that
first query for records with duplicate customer numbers.
However, I am trying to see if I can do this with just one query (possibly
using select queries or something).
Does anyone know if this is possible using just one select query???
Thanks,
Bill