-
Feb 19th, 2018, 02:22 PM
#1
Thread Starter
Member
-
Feb 19th, 2018, 08:11 PM
#2
Re: duplicate button with id feild that wont change
If that column is the primary key then it can't contain duplicate values by definition. If it really does contain a duplicate value then your database is broken. As the error message says, you can't set the value in an AutoNumber column. The whole point of that data type is that the database generates the value. Again, if your database has generated duplicate values then it is broken. Stop using that database and either go back to a backup that isn't broken or create a new database and migrate the data without the duplicate.
-
Feb 21st, 2018, 04:19 PM
#3
Re: duplicate button with id feild that wont change
one can set an autonumber field to any number within the long range
an autonumber field can have any number of duplicates
but: if one places an unique constraint on an autonumber, one can not expect to have duplicate autonumbers
after all an autonumber is nothing but a long integer
but access does not allow to update an autonumber field
cubsm22p,
why do you use a surrogate key as the primary key ?
after all, there is a perfect natural key : the order number
( unless of cource the very same order can have different order numbers ???)
do not put off till tomorrow what you can put off forever
-
Feb 22nd, 2018, 05:49 AM
#4
Re: duplicate button with id feild that wont change
cubsm22p,
you probably have already solved that problem, but anyway:
consider the following
an autonumber is nothing but a long integer
but access does not allow to update an autonumber field
but access does allow to update a long integer field
so what would be the solution to that problem ?
iow:why is the ID field of table Duptbl an autonumber and not a simple long integer ?
do not put off till tomorrow what you can put off forever
-
Feb 23rd, 2018, 02:03 PM
#5
Thread Starter
Member
Re: duplicate button with id feild that wont change
Originally Posted by IkkeEnGij
cubsm22p,
you probably have already solved that problem, but anyway:
consider the following
but access does allow to update a long integer field
so what would be the solution to that problem ?
iow:why is the ID field of table Duptbl an autonumber and not a simple long integer ?
You my friend solved the problem manipulated the field in the Duptbl after changing the criteria of that field only in that table
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|