Share Coding

Tutorials, Problems, Stuffs …

Error:Execution failed for task ‘:app:compileDebugJavaWithJavac’.

Error:Execution failed for task ‘:app:compileDebugJavaWithJavac’.
> java.lang.UnsupportedOperationException: cannot unbox java.lang.String

 

This error message I have got many times after I created a new Table in DBFlow.

That is because using a String as a auto increment Primary Key.

@Column
@Unique(onUniqueConflict = ConflictAction.REPLACE)
@PrimaryKey(autoincrement = true)
public int id;
Advertisements

One response to “Error:Execution failed for task ‘:app:compileDebugJavaWithJavac’.

  1. YMHuang (@ymhuang0808) 2016/07/24 at 11:50 am

    Thanks, it is helpful for me.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: