How to connect to a MySQL Database from an Android App?

前端 未结 3 1864
佛祖请我去吃肉
佛祖请我去吃肉 2020-12-19 22:10

I would like to connect to a MySQL Database hosted on the same server with a Tomcat Server from my Android App without using PHP. Is there any way to do this? I found some s

3条回答
  •  有刺的猬
    2020-12-19 22:38

    It should be common sense, that directly communicating with databases over the web is a "no go" security wise and with mobile devices a pain regarding the connectivity.

    Setup a webservice with JSP or Grails (which I find comes with less workload) and deploy it to your tomcat server.

    Hence the thought, you already have a Tomcat running, one assumes you have a java web app running. Try adding a webservice to that app or look in the documentation, if there already is one.

提交回复
热议问题