I am looking to create a simple xamarin.android mobile application which can connect to and interact with an SQL database hosted in azure. What would be the best way to create this connection? I have been able to create a simple console application which can do this if that helps, but am unable to do a similar thing with an android app. Thanks
You can try Azure App Service Mobile Apps to work with an SQL database hosted in Azure in your app.
Have a look at these samples from Xamarin. The "MyShoope" App in particular uses data storage.
I have provided my existing .NET Backend for reference on how to create your controllers and data entities to publish to Azure. Read through the Azure Mobile Apps tutorial to learn how to create and setup your own Mobile Apps backend for My Shoppe. https://azure.microsoft.com/en-us/documentation/articles/app-service-mobile-xamarin-forms-get-started/
Related
I am fairly new to databases, and StackOverflow(so bare with my question). My friends and I are trying to create a "student" version android app of a current school website. We just want to create something that is mobile friendly and easy to use for the students. However, the current website is a traditional web application (not REST API + SPA) and uses PostgreSQL as its database. I am wondering if we can connect a mobile app to that database to access the student's data or if we have to create a separate database.
You can use the same database but you need to create a backend service (REST API o Web Service) to comunicate the device and the database. You can use technologies like Nodejs, Go.
Hope this help you
I'm building an Hybrid App using Cordova in Visual Studio 2017, and JavaScript.
I have a SQL Server Database hosted on Google Cloud Platform and I want to access the data of this database in my App.
Which is the best way to do this in a Phonegap Cordova App? I have no idea since I've never did this before.
Thanks for now.
Though it's probably possible to access a sql database directly with some javascript magic, it's not safe. In this situation you will need your app to contact a web service which will communicate with you SQL tables to relay the information. Think of the web service as a "middle-man".
There are existing services out there, but it is also easy enough to create your own setup similarly to this: https://iphonedevlog.wordpress.com/2014/03/28/populate-your-phonegap-app-with-data-from-an-external-server-db/
I want to develop a mobile application (android app) for my company web application. So , it will use the same database with the web database. My company use mysql google cloud. How can i connect my mobile application with the database ?
Actually ran into the same scenario recently. What i did was went ahead and looked into how to specifically connect your android application to phpmyadmin, which is a database that can connect android to your web sites database. Not sure who your web host is but i have a site that is hosted by Hostgator and they implement phpmyadmin in order for the webmaster to go ahead and handle the database. For more info i have posted this link which will guide you on the proper steps to take to connect phpmyadmin to your android application.
https://www.youtube.com/playlist?list=PL0_XE0UFeWvaY5NeFcFaGmEFJmJGhnims
Hope this helps. :)
Create api interface in backend (php, etc...) through web to access database.
Use httpconnection to connect web interface and upload/download data by parameters.
How can I connect an Android application to a DB2 database stored in BlueMix?
I know that some Java libraries are missing in Android, so I can't use JDBC to connect to the database.
Any Idea?
You can not talk directly to the SQL DB on Bluemix from your android app. You will need to create an intermediary application on bluemix that talks to the db and your android app can talk to that application. You can implement this backend as a RESTful API (Java JAX-RS, Node.js w/ Express etc). The Boilerplates on Bluemix are a good place to start.
There is also the Mobile Data framework on Bluemix that simplifies this by setting up all the mobile backend for you.
I have an idea for a website that will require the use of a database to keep track of user accounts, and other things the user does on the website. I have experience with developing websites with MySQL database. I was hoping to also create an application for the website on Android and iOS. I have some experience with Android development, and I am still learning quite a lot. However, I have not done anything with databases in mobile devices.
What would be the best way to create a mobile applications and a website that the user could use to access their accounts. Would it be best to have a mobile database on the handset and sync it with the database on the server, or would it be best to have the application query the database on the server directly?
Thanks,
Michael
The best way I suggest is to use APIs.
You can create APIs to access the database through your mobile application.
You website will also be using the same database, and your mobile application will be calling the APIs to get data from the database.
May be this can help you to get started: http://www.javacodegeeks.com/2010/10/android-full-app-part-2-using-http-api.html
I think, Use web-service to communicate with web database. It is easy to use because you are using this database for both android and ios.
Thanks.