Closed turbomanage closed 10 years ago
I'm working on this. Basically, stORM needs to write out the schema along with the data when making the CSV for backup.
On further thought, stORM makes no claim to preserve column index order between versions. In SQL, you should generally reference columns by name, not index. Also related issue #18 is now fixed, although the UPGRADE strategy may still be better for you.
See https://code.google.com/p/storm-gen/issues/detail?id=39
Reported by vinzetude, Jul 31, 2013 I have a table Content with an id and a name. I need to add the column directory. So I choose to use the upgrade strategy because of the need of better performance compared to the backup/restore (with which i have the issue mentionned by d.w.flan...@googlemail.com in issue #35)
The first entry is _id : 1 | index : 0 name : bob | index : 1
After doing the alter table here what I've got directory : 1 | index : 0 _id : bob | index : 1 name : whatever | index : 2
The expected result is directory : whatever | index : 2 _id : 1 | index : 0 name : bob | index : 1
Is there a way to specify the index column of each field so that the model retrieve the right data.
Sqlite3 can't add a column before or after a specified one.
Aug 6, 2013 Delete comment Project Member #1 turbomanage Which version are you using? Does it work for you in 0.97? Status: Accepted
Aug 7, 2013 Delete comment #2 vinzetude Yes I'm currently using the version 0.97