Connection DB
This commit is contained in:
parent
03dcf9e8a3
commit
db77cf584c
Happy_Bird
.gradle
7.1.1
buildOutputCleanup
build
src/main/java/com/example/happy_bird
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -16,12 +16,11 @@ public class MariaDB
|
||||
|
||||
username="root";
|
||||
pw="HappyBird1";
|
||||
url="jdbc:mariadb://localhost/happybird";
|
||||
url="jdbc:mariadb://localhost:3306/happybird";
|
||||
driver="org.mariadb.jdbc.Driver";
|
||||
try {
|
||||
Class.forName(driver);
|
||||
con=DriverManager.getConnection(url, username, pw);
|
||||
st= (Statement) con.createStatement();
|
||||
System.out.println("Connection is successful");
|
||||
} catch (Exception e) {
|
||||
System.out.println("Fehler in der Verbindung");
|
||||
|
Loading…
x
Reference in New Issue
Block a user