java.lang.ClassNotFoundException: org.postgresql.Driver, Android

后端 未结 7 1917
借酒劲吻你
借酒劲吻你 2020-11-28 14:23

I am running Eclipse on Windows.

Following this tutorial I downloaded JDBC4, added it to my build path using Project>Properties>add External JAR, browsed for the fil

7条回答
  •  暖寄归人
    2020-11-28 14:55

    You need to add the PostgreSQL JDBC Driver in your project as mentioned in search.maven.org.

    Gradle:

    implementation 'org.postgresql:postgresql:42.2.10'
    

    Maven:

    
      org.postgresql
      postgresql
      42.2.10
    
    

    You can also download the JAR and import to your project manually.

    NOTE: Compile as used in this answer is deprecated. Replace with implementation as per 3.

提交回复
热议问题