Before creating the model object I always drop tables first like this
db.execute(' DROP TABLE IF EXISTS Products;'); db.execute(' DROP TABLE IF EXISTS Models;');but when I try to create model from Products or Models, it always throws an exception "There's no such table" exception
var products = Alloy.createCollection('Products'); var product = Alloy.createModel('Products', { fields.. }); product.save(); products.fetch();, and I know that when creating a model it creates table in DB automatically, so what am I doing wrong?
I'm using titanium sdk 3.4.1 thanks..