I am trying to create application that reads users (name,position,and their blood group). I will put these info in database to be able to achieve them when I need.
do I have to use (Sqlite database) or (Sql server database)?
it's depend on your requirement but if you want stored data locally use sqlite and if you want store data on server use sqlServer
for sqlite : http://www.vogella.com/tutorials/AndroidSQLite/article.html
for SqlServer you can not connect directly,you should use an script on your server and call it from application, or use jtds
Related
What is the difference between mySQLi (PhpMyAdmin) and SQLite (for Android database)?
Please tell me both Application (software) difference and coding difference...
They're different storage engines. MySQL is a fully fledged enterprise level database, each database and table is usually split out into multiple files which contain things such as the actual table data, as well as indexes and caches. MySQL is designed for huge database application and data processing from multiple clients.
MySQLi is just the PHP MySQL connector library to establish a DB connection and query the MySQL DB from PHP.
PhpMyAdmin is just a web gui to manage your MySQL database through PHP.
Sqlite isn't specific to Android, but its a small lightweight single file database which is designed for embedded application database. This is more for lightweight simple application data storage.
MySqli is enterprise or server based database while sqllite is small database used within application
I have software that connects to an SQL database. I am now working on the software on Android, using SQLite, and need to transfer the SQL database (with the data) to SQLite.
How can I do this?
One way would be to create the SQLite database on the device and download and persist the data into the local SQLite data base. A good place to read up on how to do this is in the Android docs.
Another possible solution would be to create the SQLite database at the server level and download it directly within the Android app then open it. But if you modify anything locally within the app you would need to send data back to the server to keep in sync.
Create Rest API that will fetch my SQL data in JSON format.
Now from android app access that API to get data and insert that data in in your SQLite.
or if you want to fetch it in background process use sync Adapter.
I need to make a app that adds data to local SQLite database and uploads data to a database so other people that use the app can download that data. I thought about loading SQLite database to online storage but I do not know how to do that or what the best way is.
This is one of the simple approach:
Your app <--->PHP webpage <----> sqlite (on server) --->url of SQLite to download
Your app need to connect to a web api, such as PHP, that can handle sqlite. You can perform sql operators via the api and then get the sqlite file by simply using its URL.
Tutorial
1.First create sqlite database
2.then create oracle database
Setup Apache server like xampp. After setup open php.ini. then delete ; before oci8.dll. then save.
C:xampp/htdocs create php webservice .
5.Call php webservice from android for download upload data.
If you can't I will help you
I've a table named student. I need to display attendance details of student by passing Student_ID. Database uses normal MySQL database on server-side to maintain the attendance register.
How to connect that MySQL Server to Android Application ?
You can refer to this tutorial but you do need a web-server for it.
Request mechanism
Android App ----> webserver ------> database (mysql)
Respond mechanism
Android App <---- webserver <------ database (mysql)
Android App will use JSON or other to get the data and display it
is it possible to connecct, or to copy the data from mysql to sqlite? I just need to store the data from mysql to sqlite.
I used mysql because im working on an online app in android and for updating puposes. i want to copy the data from mysql to sqlite so my android app will still run even there is no internet and because of that sqlite database.
please help. thanks
If you want to connect your application with my sql server, you can use some rest service to connect with database, and return results to the calling application.
Check examples of creating, consuming rest php service by following link:
http://www.androidhive.info/2012/01/android-login-and-registration-with-php-mysql-and-sqlite/
http://www.androidhive.info/2012/05/how-to-connect-android-with-php-mysql/
http://www.helloandroid.com/tutorials/connecting-mysql-database
By these methods you can fetch data from a mysql server, further to create and perform database operation on a device database use following link:
http://www.devx.com/wireless/Article/40842