Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there any possibility to sync sqlite table data between two android mobiles using wi-fi

Tags:

android

sqlite

I have developed an application in Android using sqlite database.

The data in database related to application should be same in different mobiles,if many mobiles are used.

Is it possible to sync the database data of particular application istalled in different android mobiles using Wi-Fi?

like image 275
sushma Avatar asked Dec 30 '11 12:12

sushma


1 Answers

There are a number of ways to solve this. All depend on more details in your app. Are you wanting immediate or eventual consistency? Are the phones close or distant? Is it assumed that all the communicating processes are always running? or at least running simultaneously?

You could:

a) connect the processes via sockets if the IPs are all known

b) write to a central DB and have timestamped data that each phone would update to if necc.

c) connect via bluetooth assuming close proximity

You need to provide more details. I don't think sqllite supports replication if that's what you're asking. You'd need to provide your own solution.

like image 71
ethrbunny Avatar answered Oct 13 '22 15:10

ethrbunny