Unique Key Constrain problem 
Author Message
 Unique Key Constrain problem

Hi All,

I actually experience a strange problem when executing a storedprocedure
over a ODBC connection on a SQL-Server.
The procedure is called by an ASP-Script, but that does not matter.

The problem is that I execute an INSERT INTO on a table containing a UNIQUE
KEY CONSTRAIN on a field named shortname.
I receive an errormessage telling me:
Violation of UNIQUE KEY CONSTRAIN 'name' Cannot insert dublicate key in
object 'tablename'

Fact is that the provided Shortname is definitly unique. Even stranger is
the fact that this only happens with some users who access the procedure
(they are logged in correctly and username/passwords are correct), not when
I do it. And it never happens when I try it.

Is there maybe a "hidden" connection between a constrain and the actual user
that maybe prevents the procedure from executing correctly?

Any help is kindly appreciated,

Seize the Day

(Andy Bretl)

Sun, 15 May 2005 16:09:40 GMT  
 [ 1 post ] 

 Relevant Pages 

1. Column is constrained to be unique

2. Treeview unique key problem

3. Unique Problem, needing Unique Solution.

4. Using SQL to create 2 Primary/Unique Keys in a Table

5. A Question of Unique Keys....

6. Function for unique 'key'

7. Write a unique key to a contact?

8. non-unique key - or workaround?

9. VB & Access: duplicate inserts on unique key

10. Database-locks, unique keys

11. Getting new unique key

12. Create unique primary key values


Powered by phpBB® Forum Software