0

Im new to android and Im still confused.

I have this project that whenever I update my mysql DB in the server (Im using a website in updating) my android app (I used sqlite here) informations must also be updated.. Is this possible? If yes, can you send me some links I can use?

PS: Im using lots of tables so its kinda bit problem for me to find over the internet since most of the examples are focusing on one table. A bit confusing to my part cause Im still fresh to this.

1 Answer 1

3

In your scenario, If you are using My Sql database at server side using php then you need to write sync code for each table using different techniques availables like Async Task, Retrofit , Volly etc. There may any other way to directly import data into android application. But as per my knowledge, we need to write sync logic for each table. After written sync logic for each table then we can mantain syncStatus column having values 0 and 1 for checking sync complete or not for a particular row. After complete this we can call sync method on CLICK Listener on any button or you can also called android side sync method by sending trigger to android app using push notification or gcm techniques from PHP side also. So This is the one solution as per my knowledge. You can try this. If any issue doing this. We can ask me any time. You can find out any better solution also. All the best.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.