duanao4503 2017-06-13 16:51
浏览 82

如何从我的MySQL数据库获取值到Android?

I know this topic has already a solution on stackoverflow. But for instance I can't use HttpClient to read a value from my MySQL database. So actually I am looking for a really simple code which can allow to read one value of a MySQL database. Do you have an example which works for API 24?

  • 写回答

1条回答 默认 最新

  • dpxbc88022 2017-06-13 18:43
    关注

    You need to use a library called jtds This will allow you to manage sql server connections in your Android app. However the comment is correct this will only work with MS SQL Server.

    However I found this while I was digging, apparently one of the answers denotes that if you find the correct version of MySQL Connector/J you may be able to get it working. However the functionality may only be available in the target api version that the connection driver works with. See SO post

    评论

报告相同问题?

悬赏问题

  • ¥15 spring后端vue前端
  • ¥15 寻一个支付宝扫码远程授权登录的软件助手app
  • ¥15 解riccati方程组
  • ¥15 display:none;样式在嵌套结构中的已设置了display样式的元素上不起作用?
  • ¥15 使用rabbitMQ 消息队列作为url源进行多线程爬取时,总有几个url没有处理的问题。
  • ¥15 Ubuntu在安装序列比对软件STAR时出现报错如何解决
  • ¥50 树莓派安卓APK系统签名
  • ¥65 汇编语言除法溢出问题
  • ¥15 Visual Studio问题
  • ¥20 求一个html代码,有偿