|
Post by stone77 on Mar 1, 2021 11:52:01 GMT
Hi
I was wondering whats best method on updating the project db(master db) once application is released? Currenty the Project db is in Resources folder and when app runs it creates a working copy.
The Data in the project DB will not be universal for all users for example, if people buy add-ons, the data for these add-ons will ONLY be applied to people who have access to these. (thus updating the project db and working copy db data for these users only)
Can you update the project db (thats located in resource folder in unity) via a query to add the new data? or whats the correct way to do the master update?
Best Regards
|
|
|
Post by echo17 on Mar 1, 2021 13:33:27 GMT
There are a number of ways you could do this. Depending on your setup, I would recommend having several databases, one for each optional add-on. That way you can bring these databases in as required by what the user has purchased. You can have as many databases as you want in a scene, you will just need a separate SimpleSQLManager for each one. You can also use a single SimpleSQLManager and attach the databases to that manager, consolidating them into a single database in memory where you can use joins like you would normally use on a single database. Please see Demo #9 for an example of this. I like to keep static data separate from data that the user will update at runtime into separate databases. This makes updating the static data very easy since you can just set overwrite if exists to true in the SimpleSQLManager inspector. If you are needing to update database structure without stomping on user data, you'll need to create an update path. Please see this FAQ for more information: link
|
|