allow for duplicate ticket purchases.

This commit is contained in:
2025-03-24 22:40:05 +00:00
parent 6d96998e13
commit bbab439115

View File

@@ -13,7 +13,6 @@ func InitDB(filepath string) *sql.DB {
log.Fatal("❌ Failed to open DB:", err)
}
// Thunderball results table
createThunderballResultsTable := `
CREATE TABLE IF NOT EXISTS results_thunderball (
id INTEGER PRIMARY KEY AUTOINCREMENT,
@@ -28,7 +27,6 @@ func InitDB(filepath string) *sql.DB {
thunderball INTEGER
);`
// MyTickets — flexible, multi-game ticket storage
createMyTickets := `
CREATE TABLE IF NOT EXISTS my_tickets (
id INTEGER PRIMARY KEY AUTOINCREMENT,
@@ -41,6 +39,7 @@ func InitDB(filepath string) *sql.DB {
ball5 INTEGER,
bonus1 INTEGER,
bonus2 INTEGER,
duplicate BOOLEAN DEFAULT 0,
created_at DATETIME DEFAULT CURRENT_TIMESTAMP
);`