0
More than one file was found with OS independent path 'com/mysql/jdbc/configs/maxPerformance.properties'

when I tried to build my gradle in Android Studio I am tring to use MySQL as database in my project

enter image description here

Zoe
  • 27,060
  • 21
  • 118
  • 148
  • Welcome to Stack Overflow! Please don't tag questions with the android-studio tag just because you use it: the Android Studio tag should **only** be used when you have questions about the IDE itself, and not any code you write (or want to write) in it. See [when is it appropriate to remove an IDE tag](https://meta.stackoverflow.com/a/315196/6296561), [How do I avoid misusing tags?](https://meta.stackoverflow.com/questions/354427/how-do-i-avoid-misusing-tags), and [the tagging guide](https://stackoverflow.com/help/tagging) – Zoe Mar 01 '19 at 17:06
  • Also, please don't add screenshots of code -add it into the question. And add the logs (see [mcve]) – Zoe Mar 01 '19 at 17:07

1 Answers1

0

You linked the mysql-connector-java dependency twice. I would suggest linking the dependency via:

implementation 'mysql:mysql-connector-java:5.1.45'

This dependency is available at jcenter (https://bintray.com/bintray/jcenter/mysql:mysql-connector-java).

However I would not recommend connecting directly to SQL database. I would prefer writing a REST service instead. The reasons why you should not use direct connection to database are explained here.

nestor10
  • 474
  • 4
  • 12