407-248-1481

QuoteWerks Knowledgebase Topic (Article ID 6003)

Database - Duplicate Key when saving in QuoteWerks

This information applies to :

Article ID
6003

Created/Updated
December 24, 2015

Category
Database


Are you using the most current release of QuoteWerks?
Version 24.0 Build 2
Issue:

When saving a document in QuoteWerks you receive the following or other similar messages involving a duplicate key:

First received:

The error(-2147467259) Operation must use an updateable query, was encountered in the MIDA_RecordsetEditRec function.
Error occurred at .Update method

Then:

QuoteWerks was unable to write the updated next available number sequence for QUOTE Do you want to try again?

Followed by:

Runtime error 3219:
Operation is not allowed in this context

Solutions:

1. Verify all users have Full Control rights to the QuoteWerks installation folder under Windows permissions. That's Read, Write and Modify rights.

2. If all users do have confirmed Full Control, try running Maintenance on the DOCS.MDB file. Go to Start -> Programs -> QuoteWerks -> Tools & Information -> Medic Utility then click the Maintenance button, select the Docs database and click Start.

3. If that also does not resolve the problem, in some cases we have seen the index setting for the DocumentHeaders.DocNo field somehow change to "Yes (No Duplicates)", when it should be "Yes (Duplicates Ok)". To verify this, open the database in Access 2002/2003/2007/2010/2013(Note: You can open in any version of MS Access 2002 or higher, however, do not convert the database to the new format it must remain 2002/2003 formatted.), click on the DocumentHeaders table and click on the Design button. Then scroll through the list of fields until you find the DocNo field, and click on it. In the Field Properties look for the "Indexed" property. Change it if needed. If you do need to change it, you may also want to look at the DocNo field value for each record in the table to see if there are any empty DocNo's. There should never be empty DocNo's, so for each you find, you may want to enter a unique DocNo value.

New Search