Fixed
Status Update
Comments
se...@google.com <se...@google.com> #2
I don't think this is an intended behavior.
mm...@commonsware.com <mm...@commonsware.com> #3
Note that this is still a problem as of 1.0.0-rc1.
yb...@google.com <yb...@google.com> #4
this missed the deadline for 1.0.0. We'll fix it, meanwhile, you can just provide an empty migration that does not do anything.
yb...@google.com <yb...@google.com> #5
this is actually partially correct as someone can write a query like:
select * from foo group by 1;
but we don't enforce column order for migrations and writing a query like that does not seem like the right thing to do so we'll fix this.
select * from foo group by 1;
but we don't enforce column order for migrations and writing a query like that does not seem like the right thing to do so we'll fix this.
yb...@google.com <yb...@google.com> #6
this is fixed for the next version.
note that, you still need a version upgrade to get the new behavior since we didn't want to change the existing schema files.
note that, you still need a version upgrade to get the new behavior since we didn't want to change the existing schema files.
Description
Version used: 1.0.0-alpha8
If I change the order of the member variables within an @Entity Class, I am forced to provide a migration.
Before:
@Entity(tableName = "contacts")
public class ContactEntity {
@PrimaryKey(autoGenerate = true)
private Long id;
@ColumnInfo(name = "phone")
private String phone;
@ColumnInfo(name = "name")
private String name;
@ColumnInfo(name = "mail")
private String mail;
}
After:
@Entity(tableName = "contacts")
public class ContactEntity {
@PrimaryKey(autoGenerate = true)
private Long id;
@ColumnInfo(name = "name")
private String name;
@ColumnInfo(name = "phone")
private String phone;
@ColumnInfo(name = "mail")
private String mail;
}
Is this intended behaviour?
If yes, how would such a migration look like?