Details
-
Improvement
-
Status: Resolved
-
Low
-
Resolution: Fixed
-
None
-
None
Description
Minor issue, but might be beneficial for new people. I was missing a primary key but thought it meant there was more than one primary key, and was confused for a minute. Here is the current error:
Caused by: com.datastax.driver.core.exceptions.InvalidQueryException: You must specify one and only one PRIMARY KEY
at com.datastax.driver.core.ResultSetFuture.convertException(ResultSetFuture.java:252)
at com.datastax.driver.core.ResultSetFuture$ResponseCallback.onSet(ResultSetFuture.java:119)
at com.datastax.driver.core.RequestHandler.setFinalResult(RequestHandler.java:202)
at com.datastax.driver.core.RequestHandler.onSet(RequestHandler.java:319)
Recommend considering two different error messages, ie:
- No primary keys were found, when exactly one is required.
- Multiple primary keys were found, when exactly one may be specified.