javaweb學習4

XYu1230發表於2024-09-28

今天主要學習了獲取資料庫連線的操作和maven
maven匯入mysql和druid jar包
具體的jar座標可以去這個網站找
https://mvnrepository.com/

 <dependencies>
        <dependency>
            <groupId>mysql</groupId>
            <artifactId>mysql-connector-java</artifactId>
            <version>8.0.25</version>
        </dependency>

        <!-- https://mvnrepository.com/artifact/com.alibaba/druid -->
        <dependency>
            <groupId>com.alibaba</groupId>
            <artifactId>druid</artifactId>
            <version>1.2.8</version>
        </dependency>


    </dependencies>

相關文章