When you tried to start the Spring Boot application, you got this error:
org.hibernate.exception.SQLGrammarException:
Unable to obtain isolated JDBC connection
[Unknown database 'spl_auction_db']
Root Cause: The MySQL database spl_auction_db doesn't exist yet.
- Application tries to connect to MySQL database at startup
- Hibernate configuration is set to
ddl-auto=update(which updates existing schema) - But database must exist first for Hibernate to connect
- Database was never created manually
- MySQL Server 8.0+ installed
- MySQL is running
- You have access to MySQL with credentials:
root/soumya@0210
-
Open MySQL Workbench
- Start → Search → MySQL Workbench → Open
-
Create New Query
- File → New Query Tab
- Or click the "+" icon next to query tabs
-
Paste SQL Command
CREATE DATABASE IF NOT EXISTS spl_auction_db;
-
Execute
- Click lightning bolt icon (Execute)
- Or press Ctrl+Enter
-
Verify Success
- You should see message: "Query executed successfully"
- In left panel, refresh (right-click Schemas → Refresh)
spl_auction_dbshould appear
Windows PowerShell:
# Navigate to your project
cd "C:\Users\soumyadeep DEY\IdeaProjects\SPL-2"
# Create database
mysql -u root -psoumya@0210 -e "CREATE DATABASE spl_auction_db;"
# Verify
mysql -u root -psoumya@0210 -e "SHOW DATABASES LIKE 'spl_auction_db';"Windows Command Prompt:
mysql -u root -psoumya@0210 -e "CREATE DATABASE spl_auction_db;"If mysql command not found, use full path:
"C:\Program Files\MySQL\MySQL Server 8.0\bin\mysql" -u root -psoumya@0210 -e "CREATE DATABASE spl_auction_db;"cd "C:\Users\soumyadeep DEY\IdeaProjects\SPL-2"
# Clean build
.\mvnw clean compile
# Run application
.\mvnw spring-boot:run[INFO] BUILD SUCCESS
...
2026-01-01T... INFO 12345 --- [ restartedMain] o.s.b.w.e.tomcat.TomcatWebServer: Tomcat started on port(s): 8080
2026-01-01T... INFO 12345 --- [ restartedMain] com.example.spl2.Spl2Application: Started Spl2Application in X.XXX seconds
http://localhost:8080/index.html
-
Hibernate Auto-DDL: Spring Boot automatically creates tables:
players- Player datateams- Team databids- Bid historyauction_state- Auction progress
-
No Manual SQL Needed: All tables created automatically
-
Database Ready: You can immediately start using the application
File: src/main/resources/application.properties
spring.datasource.url=jdbc:mysql://localhost:3306/spl_auction_db?useSSL=false&serverTimezone=UTC
spring.datasource.username=root
spring.datasource.password=soumya@0210
spring.jpa.hibernate.ddl-auto=updateWhat each line means:
url: Connect to MySQL on localhost, port 3306, databasespl_auction_dbusername: Login as userrootpassword: Password issoumya@0210ddl-auto=update: Automatically create/update tables if needed
- Open MySQL Workbench
- Look at left panel under "SCHEMAS"
- Find
spl_auction_db - Click arrow to expand
- Should see tables after running application:
- players
- teams
- bids
- auction_state
mysql -u root -psoumya@0210 spl_auction_db -e "SHOW TABLES;"Should output:
+------------------------+
| Tables_in_spl_auction_db|
+------------------------+
| auction_state |
| bids |
| players |
| teams |
+------------------------+
Solution: Follow the "How to Fix It" section above
Solution:
- Check password is exactly:
soumya@0210 - Make sure no typos
- Verify MySQL user 'root' exists
Solution:
- MySQL is not running
- Windows: Start → Services → MySQL80 → Start
- Or in Command Prompt (as Admin):
net start MySQL80
Solution:
- MySQL bin directory not in PATH
- Use full path:
C:\Program Files\MySQL\MySQL Server 8.0\bin\mysql - Or add to system PATH
Solution:
- Restart the Spring Boot application
- Clear any cached connections
- Check connection properties in
application.properties
After starting the application, test these:
- Homepage loads: http://localhost:8080/index.html
- Add a team: Click "Add Team" button
- Register a player: Click "Register Player" button
- Start auction: Click "Auction" button
- Tables created: Check database (see "Verify" section above)
- Version: 8.0+
- Charset: utf8mb4 (default)
- Collation: utf8mb4_unicode_ci (default)
- Engine: InnoDB (default)
- DDL Mode:
update(auto-create/update tables) - Show SQL:
false(don't log all SQL) - Format SQL:
true(pretty print SQL in logs)
- DATABASE_SETUP.md - Comprehensive database setup guide
- QUICK_DATABASE_FIX.txt - Quick reference card
- This file - Complete problem and solution
- ✅ Create database (follow "How to Fix It" above)
- ✅ Restart application
- ✅ Access http://localhost:8080/index.html
- ✅ Start using the system!
If you still have issues:
-
Check MySQL is running
- Windows: Services → MySQL80 should say "Running"
- Test:
mysql -u root -psoumya@0210 -e "SELECT 1;"
-
Verify credentials
- Check
application.propertiesfor correct username/password - Test:
mysql -u root -psoumya@0210 -e "SHOW DATABASES;"
- Check
-
Check database exists
- Command:
mysql -u root -psoumya@0210 -e "SHOW DATABASES LIKE 'spl_auction_db';"
- Command:
-
Check port 3306 is open
- Firewall might be blocking
- Windows Defender → Allow MySQL through firewall
Status: ✅ Complete Fix Available
Time to Fix: ~5 minutes
Difficulty: Easy - Just create one database
After Fix: Application will be fully functional!