4/5 Databases and ORM

Learning Outcomes 1

  1. Use the Database tab in IntelliJ to make a database

  2. Use the Console in IntelliJ to create database tables, populate data, and perform queries

  3. Connect to a database in a command line program and perform basic operations

Learning Outcomes 2

  1. Connect to a database in a JavaFX program and perform basic operations

  2. Use combo boxes and text areas

  3. Reconnect to a database in a project from GitHub

  4. Write a PreparedStatement

Resources

Exam Topics

  • Connect to and perform database SQL operations, process query results using JDBC API

Oracle Academy

  • 6-1 JDBC Introduction

  • 6-2 JDBC Basics

Section 6 Quiz

Textbook

  • 24 Accessing Databases with JDBC

Tutorial / Practice Activity

  • 6-1 Practice

  • 6-2 Practice

Lesson Plan

Week 4

  • Mindfulness

  • Previous week review

  • Resource reinforcement and clarification

  • Database fundamentals

  • ER diagrams

  • Database options: Derby, MySQL, H2, MariaDB

  • Database installation and connection

    • H2 in IntelliJ

  • Diagrams in IntelliJ

    • Right click database in Database tab -> Diagrams -> Show Visualization

  • Connect to a database in a command line program - 6-1 Lesson and Practice

    • Register JDBC driver

    • Open a connection

    • Execute a query

      • Store result in a ResultSet

      • Process ResultSet

    • Clean-up environment

  • OOP Project

    • Register and enroll in repl.it

    • Quality, style, and documentation expectations

Week 5