如何在线保存/备份每个用户的ROOM数据库内容?

huangapple go评论62阅读模式
英文:

How can I save/ backup the contents of each users ROOM database online?

问题

我的应用程序(一个健身追踪器)相当依赖ROOM数据库。

这是存储所有客户数据以及运动信息的地方。

然而,问题在于如果用户更换手机或删除应用程序,所有数据都会丢失。

如何备份这些数据/是否有办法将每个用户的ROOM数据库内容保存在线?

英文:

My application (a workout tracker) relies quite heavily on a ROOM database.

This is where all of the customers data, as well as exercise info is stored.

However the problem with this is that if a user changes phone, or deletes the app all of the data is lost.

How can I backup this data/ is there a way to save the contents of each users ROOM database online?

答案1

得分: 2

你需要另外一个数据源来同步你的数据。例如,你应该在服务器上设计一个数据库,编写一个API,并将你的数据放在在线数据库中。如果你不了解Web编程,也许firebase数据库可以帮助你。

英文:

You need another datasource to sync your data.
ie, you should design a database on a server, write an api and put your data on the online database.
If you don't have knowledge of web programming, maybe firebase database can help you.

huangapple
  • 本文由 发表于 2020年8月9日 14:54:06
  • 转载请务必保留本文链接:https://go.coder-hub.com/63323359.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定