Skip to content
This repository has been archived by the owner on Aug 26, 2019. It is now read-only.

Cerelius/BudgetTracker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

To USE LINKER IN OTHER UI CLASSES
(A working example of this is in the AddAccount class)

- class must import java.sql.*

- create method for SQL functionality:
    public void testDB() throws SQLException{
        Connection conn = get_connection();
        Statement stmt = conn.createStatement();
        String sql = "SELECT * FROM Users where Username = ?";
        PreparedStatement prepared_statement = conn.prepareStatement(sql);
        String username = "SuperKoolUser91";
        prepared_statement.setString(1, username);

        ResultSet rs = prepared_statement.executeQuery();
        ResultSetMetaData rsmd = rs.getMetaData();
        conn.close();
        }
   
 - to call SQL method :
        try {
          testDB();
        } catch (SQLException e1) {
          e1.printStackTrace();
			

About

CSC 450 Budget Tracking Applicaiton

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages