Code used in video "Java prog#2 . Connect Sqlite or MySQL database to Netbeans IDE"

Here I am providing the downloadable code link of  the java code I have used in the video
 "Java prog#2 . Connect Sqlite or MySQL database to Netbeans IDE"  of my YouTube channel ProgrammingKnowledge

Click Link to watch the video LINK


import java.sql.*;
import javax.swing.*;
public class javaconnect {
Connection conn= null;
public static Connection ConnecrDb(){

try{
Class.forName("org.sqlite.JDBC");
Connection conn =DriverManager.getConnection("jdbc:sqlite:project123.sqlite");
//JOptionPane.showMessageDialog(null, "Connection Established");
return conn;
}catch (Exception e){
JOptionPane.showMessageDialog(null, e);
return null;

}

}
}

Java prog#1. Create netbeans project and download SQLite Manager from firefox (web browser)




SQLite is a software library that implements a self-contained, serverless, zero-configuration, transactional SQL database engine. SQLite is the most widely deployed SQL database engine in the world. The source
code for SQLite is in the public domain


Java prog#2 . Database Connection (Sqlite or MySQL ) to Java 

.


java netbeans and MySQL or SQLite  connecting to database
Connecting to a MySQL Database in Java
connecting to a database with java code
Database Programming with JDBC and Java
Trying to connect to mysql database via JDBC
Connect to MySQL database from Java
What is Jdbc and how you connect Java with database

Comments

  1. As conn, pst is used in javaconnect class.... So, it is not showing correct in Saving JFrame.... So, can u tell me how to do that?

    ReplyDelete

Post a Comment