开发者

how to store parsed xml file to a sqlite database in Android?

开发者 https://www.devze.com 2023-02-25 05:44 出处:网络
i am making a project in that i required synchronize data between server mysql data and local sqlite data...

i am making a project in that i required synchronize data between server mysql data and local sqlite data... With the help oh php i have created mysql data XML file.... so now i know the parsing of xml data but how can i store it开发者_如何学Go in sqlite(local) database ??

Please help me i ll appreciate your help ...


So if you are parsing xml file you have key-value structure and maybe something else so create database with column named by parameters, for each row insert name of node or its own id and then values which you need, if you need to use only key-value maybe better way it'll be to put it into shared preferences.

Another option, jut save whole xml as a standard string(text) and then you can get it and parse it once again.

Everything depends on that what kind of structure you have.

HERE information about storing in database

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号