Issue Details (XML | Word | Printable)

Key: NUCMONGODB-46
Type: New Feature New Feature
Status: Closed Closed
Resolution: Duplicate
Priority: Blocker Blocker
Assignee: Unassigned
Reporter: Arny
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
DataNucleus Store MongoDB

@PrimaryKey not supported

Created: 06/Jul/11 03:32 AM   Updated: 01/Aug/11 05:15 PM   Resolved: 06/Jul/11 09:21 AM
Component/s: None
Affects Version/s: 3.0.0.m1, 3.0.0.m2, 3.0.0.m3, 3.0.0.m4, 3.0.0.m5, 3.0.0.m6, 3.0.0.release
Fix Version/s: None

Forum Thread URL: http://www.datanucleus.org/servlet/forum/viewthread_thread,6757


 Description  « Hide
When using:
        @PrimaryKey
        @Persistent(valueStrategy = IdGeneratorStrategy.IDENTITY)
        protected String key;

an exception is raised on query execution:
org.datanucleus.exceptions.NucleusException: The key value passed to construct a SingleFieldIdentity of type "class javax.jdo.identity.StringIdentity" for class "class dbobject.Application" is null.

Sort Order: Ascending order - Click to sort in descending order
Andy Jefferson added a comment - 06/Jul/11 09:21 AM
NUCMONGODB-45 fixed all of that and other things. Obviously you could contribute tests to the test suite if you think you have some other situation.
PS For future reference, all bug reports have to be accompanied by a valid testcase

Arny added a comment - 06/Jul/11 03:14 PM
I've added a testcase on the forum to demonstrate the issue.
Using m6 snapshot.