473,404 Members | 2,213 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,404 software developers and data experts.

Duplicate Values

I'm using Ms Access 2003.
I have five tables called
tblAllContract
tblType
tbInteranlContact
tblSupplier
tblManager

The other four tables are linked to tblAllContracts with Id's.I have a bound form called frmViewContracts where i view all my contracts on the system.This form is from query called qryViewContracts.

I have 150 contracts that are stored on the system.Since i dont want my users to to go through all the contracts when they want to view a specific contract I created a combo combo box from the qryViewContracts where the the users selects the contract they want to view and the information gets populated in the appropriate fields.

The problem is everytime i close the form it gives me an error saying The changes you requested to the table were not successful because they would create duplicate values in the index, prinary key, or relationship. Changes the data inthe field or fields that contain duplicate data, remove the index or redifine the index to permit duplicate entries and try again.The thing is i'm not doing any changes i'm just populating the data in the fields
Jan 23 '08 #1
2 1842
MMcCarthy
14,534 Expert Mod 8TB
Something else is going on, unfortunately there is not enough information here to say what.

What is the record source of the main form?
Is the combo box in the form header?
Have you set the control source of the combo box to anything?
Are you populating the data on the main form or in a subform?
Feb 5 '08 #2
mshmyob
904 Expert 512MB
As msquared says we need more info on your design.

But if your fields on your form are bound you ARE changing data when you populate them. Then closing the form tries to save your changes.

I'm using Ms Access 2003.
I have five tables called
tblAllContract
tblType
tbInteranlContact
tblSupplier
tblManager

The other four tables are linked to tblAllContracts with Id's.I have a bound form called frmViewContracts where i view all my contracts on the system.This form is from query called qryViewContracts.

I have 150 contracts that are stored on the system.Since i dont want my users to to go through all the contracts when they want to view a specific contract I created a combo combo box from the qryViewContracts where the the users selects the contract they want to view and the information gets populated in the appropriate fields.

The problem is everytime i close the form it gives me an error saying The changes you requested to the table were not successful because they would create duplicate values in the index, prinary key, or relationship. Changes the data inthe field or fields that contain duplicate data, remove the index or redifine the index to permit duplicate entries and try again.The thing is i'm not doing any changes i'm just populating the data in the fields
Feb 5 '08 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

8
by: Mark | last post by:
When my form goes to a new record, I have a procedure that copies the last record added to the form's underlying table into the form. The intent is that a series of new records may have the same...
9
by: vbportal | last post by:
Hi, I would like to add BitArrays to an ArrayList and then remove any duplicates - can someone please help me forward. I seem to have (at leaset ;-) )2 problems/lack of understanding (see test...
4
by: sri2097 | last post by:
Hi all, I'm storing number of dictionary values into a file using the 'cPickle' module and then am retrieving it. The following is the code for it - # Code for storing the values in the file...
3
by: skennd | last post by:
Here's my problem in exact replication: I have used the find duplicate query in Access, and the query determined the following duplicate values by the following query: In (SELECT FROM As...
5
by: Manish | last post by:
The topic is related to MySQL database. Suppose a table "address" contains the following records ------------------------------------------------------- | name | address | phone |...
4
by: FangQ | last post by:
hi I am very new to mysql. I have a question about using the "on duplicate update" clause with insert command. my table "data" has two columns, field1 and field2, where field1 is the index...
2
by: mavmavv | last post by:
I have a Form where I have created a duplicate record button, no problem... The subform is where my problem lies. The subform displays data matching the mainform's ID, these two values are...
3
by: rajeshkrsingh | last post by:
Hi friends, Step1- create table duplicate ( intId int, varName varchar(50) ) insert into duplicate(intId,varName) values(1,'rajesh') insert into duplicate(intId,varName) values(2,'raj12')...
2
by: raphael001 | last post by:
In my Visual Basic program I'm just trying to find duplicate values entered into an array from an inputbox, but i can't seem to get the coding right on the final part to check for duplicate values...
4
by: ramdil | last post by:
Hi All I have table and it have around 90000 records.Its primary key is autonumber field and it has also have date column and name, then some other columns Now i have problem with the table,as my...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.