title: I'm trying to connect my databse on java, what might be the cause of error?
body: <p>What I want is to get data from my database which I saved on my workspace folder, I also installed the latest sqlite-jdbc jar...</p>
  
  <p>I followed the tuts here <a href="http://www.tutorialspoint.com/sqlite/sqlite_java.htm" rel="nofollow noreferrer">http://www.tutorialspoint.com/sqlite/sqlite_java.htm</a>
  here is my code:</p>
  
  <pre><code>import java.sql.*;
  import javax.swing.*;
  
  public class sqliteConnection {
  
      Connection conn = null;
  
      public static Connection dbConnector(){
          try{
              Class.forName("org.sqlite.JDBC");
              Connection conn = DriverManager.getConnection("jdbc:sqlite:TR.sqlite","","");
              JOptionPane.showMessageDialog(null, "Connection Successful");
              Statement stmt = null;
  
              stmt = conn.createStatement();
              ResultSet rs = stmt.executeQuery("SELECT * FROM admin_tbl;");
              while ( rs.next() ) {
                  int id = rs.getInt("admin_id");
                  String  user = rs.getString("username");
                  String  pass = rs.getString("password");
                  System.out.println( "ID = " + id );
                  System.out.println( "NAME = " + user );
                  System.out.println( "ADDRESS = " + pass );
                  System.out.println();
              }
              rs.close();
              stmt.close();
              return conn;
          }catch(Exception e){
              JOptionPane.showMessageDialog(null, e);
              System.out.println(e);
              return null;
          }
      }
  
  }
  </code></pre>
  
  <p>First i get the result of "Connection Successful" then
  I get this error...</p>
  
  <pre><code> java.sql.SQLException: [SQLITE_ERROR] SQL error or missing database (no such table: admin_tbl)
  </code></pre>