-
Notifications
You must be signed in to change notification settings - Fork 583
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error: Class cannot be read from Sqlite3 database. #20
Comments
I'm seeing the same error when using the 1.1 jar. It cleared up when I pulled down the latest source and just dropped it in directly. The jar may need to be rebuilt? |
Yes. It has been corrected in the latest code. It was an incorrect path in the inflate method of SugarRecord. You could build the jar again or use it as library. I'll release the 1.2 jar soon. thanks. |
Thanks Satyan! Terrific library, btw, extremely simple and lightweight. |
Thanks @noelb .. Let me know if you have any ideas to improve it further.. Closing this issue. |
Thanks. Cool lib by the way :) |
Hi, I use the version 1.2 of sugar and I have an error message "class cannot be read from sqlite3 database" so I can't modify the value of a column. Any suggestions to fix this? |
@Marwen1990 can you post your class here (or in private to me).. thanks. |
package com.example.newproject; import android.content.Context; import com.orm.SugarRecord; public class Contact extends SugarRecord{
} Activity : package com.example.newproject; import java.util.List; import android.app.ListActivity; import com.orm.query.Select; public class CheckActivity extends ListActivity {
} |
Do you need the context property in contact class? That looks like the issue. That would make sure that sugar doesn't try to persist context. |
Or without Context haw can I save an element in the table contact for example? I tried to remove the Context but when I try to save an element an error "Nullpointerexception" was made. |
My Class:
public class BankAccount extends SugarRecord{
String name;
String alias;
I can create new entries (The logs are saying that):
BankAccount bankAccount = new BankAccount(context, sms.getAccount());
bankAccount.save();
But I when I try to get a list of all entries with:
List bankAccounts = BankAccount.listAll(BankAccount.class);
I get a list with all entries but this error, too:
05-15 19:22:37.977: ERROR/Sugar(13045): Class cannot be read from Sqlite3 database.
The text was updated successfully, but these errors were encountered: