I am currently developing an Android application. I want to be able to access MySQL from my website directory without needing to use JSON, SOAP or PHP in order to access MySQL. Is it possible to to import a MySQL connector into an android app.
Thanks for the help
You can use protoBufs instead by Google or use mySQL's connector example here but using the connector wouldn't be safe as #Shaun said in his answer. So it is possible.
Wow, I like how someone actually said its not possible. This is java we are working with isnt it? Its not easy is the answer. You can always take a java library already written for this in full out java, and rewrite it to work with android. The problem? Its not easy, thats why there is not a very well known library for it yet. Theres alot of connection issues, and security issues to think about when doing this from a phone. One, you dont have a dedicated stream of connection (meaning, your connectivity could drop at any moment) and your data could be corrupt, or, you query coudl have left out the LIMIT at the end you could whipe your database. Secondly, you have to worry about the security of your database. Phones are in no way the most secure devices out there, let alone android.
No this isn't possible. You'll require a web service front end.
Related
I'm developing my first android app (a social media kind-of App) and after some research found that a graph database (specifically Neo4j) could be the adecuate solution for data storage. I've been also been in touch with graph theory and graph algorithms lately and decided to give it a shot.
I've grown an interest on GDB due to how intuitive and easy is to understand and represent relationships between entities this kind of DB. I've also liked Cypher Query Language (Neo4j Query Language) intuitiveness for retrieving information from graphs. Thats the reason I would like to connect my app with a Neo4j database.
What I want to do is remotely storing my users database and retrieve user information for login. After some research I've found that Neo4j has different language's drivers including one for Java. And since Java is Android official language I would like to know if Neo4j java API will work on my Android project. Reading through Neo4j API documentation though, there's a statement that says that it has been deprecated and that I should use cypher and procedures instead, but I've failed on finding documentation about this. What would be the way to connect my app with a neo4j GDB using Cypher and procedures?.Where can I find some tutorials, documentation, examples to achieve
Please keep in mind that I'm still a beginner in Android development and GDB. Any help will be appreciated.
Forget REST. Look for using graphql (pros: only data you need, less network calls). There must be a lib for Android to consume gql, certainly from FB.
Look for the graphql plugin at https://github.com/neo4j-graphql/neo4j-graphql
However, be aware of security if you put your gdb on the web directly.
Will Lyon (Neo4j)'s article : https://www.oreilly.com/learning/building-a-simple-graphql-server-with-neo4j
I need to connect my android application to my firebird DB
do someone knows how to do this?
please write the code!
I'm not particularly familiar with Firebird, but my guess is the best approach would be to use a web service of some sort (RESTful?) which allows your Android client to communicate with the database. This is the solution that is typically used for most apps since you can't connect directly to the database from Android. It's also good from a design standpoint because your application does not depend on the underlying database itself, but rather the web service which acts as a mediator, meaning you can swap database implementations without impacting your client.
Since Jaybird (Firebird JDBC driver) doesn't support Android, you need something more "hackish". Commercial solution would be using midware, eg RemObjects DataAbstract supports Android (pre-order/beta stage) and Firebird: http://www.remobjects.com/da/java.aspx
You can try this Jaybird port for Android:
http://sourceforge.net/projects/androidjaybird
I am currently working on an Android project and will have to manage database connection and queries to store data. I will not be working with SQLite as provided by the Android device and using it is not an option.
As I need to build quite a lot of queries I wanted to use a library or framework to make the task easier. Looking at what was available, it seemed easiest to use a framework such as, for example, QueryDSL.
However, since I am working on Android, I am not sure if the framework is usable and what using it would entail. Does somebody have experience using an external database with Android and have any recommendations?
The recommended way to connect to an external database is to use a REST client.
See this post
HeyHo,
which opportunities do I have to implement a client-server architecture for an android application. I simply want to transmit results from my database server to my application. I was researching on the internet and found different solutions but I ain't sure which one fits the best and is the simplest one:
- XML-RPC
- RESTlet
- REST + JSON
Maybe there is even a more simple way to do this and I haven't considered it yet.
Thanks for your helpful answers in advance
Cheers
Ei.Schinken
AFAIK, Rest+JSon is best option and simple to do and there are lot of references available for help.
Depends on yout server architecture, for example We have here a Mysql database with PHPmyadmin, so I'm using Json with PHP, and works fine for me.
I want to connect an android mobile program to a C++ program, and i dont really know how it should be done.
I was thinking about a Bluetooth connection, but i dont really know how to handle bluetooth in C++. Could you give me some general advice about this?
If you think that i should use another kind of connection, like tpc-ip based, please, let me know and give me some general advices too.
I need the data transfer to be fast, because im trying to use the android device as an interactor, so i need a fast feedback from the C++ program.
Thanx.
If I were you, I would use a TCP/IP connection. It is very easy to implement in Java (Android) and also in C++. Besides, it makes it easy to change the frontend later on. And it is as fast as your network connection, which is usually faster than bluetooth.
Just make sure you put enough effort in the design of your protocol.
There are a lot of resources to be found on the internet on how to create TCP/IP connections, both in Java and C/C++.
If you wanted to have a client server model kind of an use here. Better is to host your Server app(Port your C++ app to Java servlets) & access the Server app via http via Android client. Webviews in android are very useful in doing these.