Duplicate entries

G

Guest

I have a table(ContactsInterviews) that has InterviewID, ContactID, CustomerID, Date, Time. Relationships between Contacts, Customers, and ContactsInterview are setup. I need a solution that when assigning a new interview to a Contact to a Customer, that there is not a duplicate interview on the same Date and Time as another Contact. I think I need a DLookup to read all records with the same CustomerID and the compare the Date and Time from the form to the table. Or possibly some VB code? Not sure. I am somewhat new to Access but have come a long way in the past 2 months.
 
G

Gerald Stanley

The neatest solution would be to create a Unique Index on
the columns CustomerId, Date and Time in the Contacts
Interviews tables.

Hope This Helps
Gerald Stanley MCSD
-----Original Message-----
I have a table(ContactsInterviews) that has InterviewID,
ContactID, CustomerID, Date, Time. Relationships between
Contacts, Customers, and ContactsInterview are setup. I
need a solution that when assigning a new interview to a
Contact to a Customer, that there is not a duplicate
interview on the same Date and Time as another Contact. I
think I need a DLookup to read all records with the same
CustomerID and the compare the Date and Time from the form
to the table. Or possibly some VB code? Not sure. I am
somewhat new to Access but have come a long way in the past
2 months.
 
G

Guest

Problem, I have many Customers and many more Contacts. Creating unique indexes on CustomerID, Date and Time allows only one customer to see Contacts at a specified Date and Time. I scheduled about 75 Contacts per week with at least 3 interviews with various Customers

----- Gerald Stanley wrote: ----

The neatest solution would be to create a Unique Index o
the columns CustomerId, Date and Time in the Contact
Interviews tables

Hope This Help
Gerald Stanley MCS
-----Original Message----
I have a table(ContactsInterviews) that has InterviewID
ContactID, CustomerID, Date, Time. Relationships betwee
Contacts, Customers, and ContactsInterview are setup.
need a solution that when assigning a new interview to
Contact to a Customer, that there is not a duplicat
interview on the same Date and Time as another Contact.
think I need a DLookup to read all records with the sam
CustomerID and the compare the Date and Time from the for
to the table. Or possibly some VB code? Not sure. I a
somewhat new to Access but have come a long way in the pas
2 months.
 
G

Gerald Stanley

Can you confirm that you have created only one unique index
for those three columns not three unique indexes. I have
simulated this and am unable to create a row for contact2
to meet with customer1 at the same date and time as
contact1 is meeting with customer1.

Gerald Stanley MCSD
-----Original Message-----
Problem, I have many Customers and many more Contacts.
Creating unique indexes on CustomerID, Date and Time allows
only one customer to see Contacts at a specified Date and
Time. I scheduled about 75 Contacts per week with at least
3 interviews with various Customers.
 
G

Guest

Thanks,
Found the answer to my previous question. I had to create a index then leaving the following index names blank choosing only the fields column. Thanks for all the help
 

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