AWS DynamoDB - sync localhost db with server hosted db? - android

I'm very new to working with databases in general! I'm working with DynamoDB for a mobile app and I recently discovered that I could use Python to script table creation and data entry by running DynamoDB locally on my computer. Now, intuitively, I thought there must be a way to test my database and locally, but then push the changes to my server hosted DB. But after countless searches on Google, I still can't find a way to do so and it doesn't seem like this concept exists?
Can anyone fill in the blanks for me here? Thanks!

Are you using DynamoDBLocal for testing your changes?
If so, DynamoDBLocal is meant to be a standalone application purely for offline testing. There is no way or mechanism to sync the changes to the local database to the API hosted service.

Related

How to access postgreSQL database from android mobile using python

I wand to access the postgreSQL database from android using Pydroid3 application in my mobile phone. to access postgreSQL database i need to import psycopg2, but android doesn't support this.
can anyone please suggest the way to solve this issue.
With Android you typically don't make a hard database connection, unless its a local one.
psycopg2 doesn't work for the same reason you're not supposed to use JDBC . You should talk to a remote database via a RESTful API, meaning a server sends you data that it itself retrieves from the database.
So your next step would to create a web site/service that handles GET requests. So your app can talk to it, and it can talk to the database.

What SQL databases are used in Android to build a simple app with a login system?

I'm trying to build an Android app where the database is on the server side.I hear that SQLite is a local database so it doesn't really work for what I'm trying to do.
In java I would use JDBC to connect to MySQL and send requests normally.
In PHP too it's almost the same thing.
The app needs a login system and all of that...
How can I do this in Android ?
Android does not support MySQL out of the box, but you can implement it.
Probably the SQLite you heard about, in the Android environment, refers to Room, the standard to save persistent data locally on the device.
In the mobile world, often a good option (if they fits for you) are NoSQL databases. There are plenty, hosted services like Firebase, DynamoDB or open source like MongoDB, Supabase.

Creating Android Apps with MongoDB

How can I create an android app that uses a mongoDB database locally i.e. Clients can make CRUD operations without connecting to a server. Sort of how SQLite is used, except this time I wanna use mongoDB.
I have checked around and what seems to be my most suitable option is using mongodb java driver, but the problem is how and what am I connecting the mongoClient to? Do I have to sort of start a server or something?
I would suggest using firebase or realm or something that comes with better native mobile support. Couchbase Mobile might be of interest too, but I have not used it. https://developer.couchbase.com/mobile

Android App Offline Sync to Azure SQL Server and Blob Storage

I've created an Android App which the user creates data in an SQLite database and also creates picture and audio files. The next stage is to create an offline sync to Microsoft Azure (SQL Server and Blob Storage). There will be multiple devices for the App which all need to sync, so data on all devices will be the same.
What is the best method that encapsulates Android App SQLite to Microsoft SQL Server and created files to blob storage in Azure which will handle two way sync?
I've looked at Azure's MobileServiceClient but don't think that totally fits my needs as its just data tables. Maybe Sync Adapter instead?
I'm thinking I should create my own sync but not sure where to start? I think in the app i want to keep a changes table so when data is created or changed its logged in the table and then when it syncs it looks at this table and transfers the data and files. Then on the server side I'm not sure how to handle syncs from multiple devices so that all devices have the same data.
Anyway any pointers would be great.
Thanks
There is a similar SO thread Upload images to Azure Blob Storage from an Android device With Offline Sync which discussed about offline sync for files with Azure Storage, that may helpful for you, but now Azure Mobile SDK for Android in Java doesn't support it, just implement the feature by self. If using Xamarin for Android, there is a solution introduced in the offical blog, that you can refer to and possibly implement this in Java.
Hope it helps.

syncing android database with server with intermittent internet conectivity

so I am writing an android app that will be used at a point of sale in some shops for survey questions. I have a java jsf web app using jpa with a mysql database that I want to sync with, preferably both ways but only a couple of tables. The android app will have only a few tables and will not replicate my server database completely. Unfortunately the android apps will in some places have only intermittent internet access that will drop in and out. I am currently looking at different options to use to store my data on android. I have looked at:
writing my own sync between the database on my server and SQLite on android but there has to be an easier option
storing my data on app engine and syncing with app engine as per the example in the android developers guide however I am not sure how my limited internet connectivity will work
using couchdb but I dont really want to go down this route as I already have the server side set up
does anyone have any ideas?
can I store data locally using android then sync with app engine when I have a connection?
Thanks

Categories

Resources