Skip to content
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

How to add new field ? #195

Open
FeiCheung opened this issue Aug 31, 2016 · 1 comment
Open

How to add new field ? #195

FeiCheung opened this issue Aug 31, 2016 · 1 comment

Comments

@FeiCheung
Copy link

my code:
f (window.openDatabase) {
persistence.store.websql.config(persistence, 'testdb',
'My SQLite database', 5 * 1024 * 1024);
} else {
persistence.store.memory.config(persistence);
}

var User = persistence.define('User', {
name: "TEXT",
age: "INTEGER"
});
persistence.schemaSync();

my app's being in production I want to add a new field ‘sex’ to the 'user'schema.

var User = persistence.define('User', {
name: "TEXT",
age: "INTEGER",
sex:"TEXT"
});

I dont want uninstall my app , how could I add this field ?? thanks for help

@0scar14
Copy link

0scar14 commented Aug 31, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants