comparison now works as required

This commit is contained in:
2025-02-13 21:51:39 +11:00
parent 14de3f1790
commit 1272d3a786
4 changed files with 66 additions and 48 deletions

8
db.py
View File

@@ -62,7 +62,9 @@ def init_db():
CBA_price REAL,
Overseas_trip_date STRING,
Mark_reno_date STRING,
Sell_shares INTEGER
Sell_shares INTEGER,
CBA INTEGER,
TLS INTEGER
)''')
cur.execute('''CREATE TABLE IF NOT EXISTS comparison_savings_data (
@@ -153,13 +155,13 @@ def insert_cset( data ):
name, D_Salary, D_Num_fortnights_pay, School_Fees, Car_loan_via_pay,
Car_loan, Car_balloon, Living_Expenses, Savings, Interest_Rate, Inflation, Mich_present,
Overseas_trip, Mark_reno, D_leave_owed_in_days, D_TLS_shares, M_TLS_shares, D_CBA_shares,
TLS_price, CBA_price, Overseas_trip_date, Mark_reno_date, Sell_shares
TLS_price, CBA_price, Overseas_trip_date, Mark_reno_date, Sell_shares, CBA, TLS
)
VALUES (
:name, :D_Salary, :D_Num_fortnights_pay, :School_Fees, :Car_loan_via_pay,
:Car_loan, :Car_balloon, :Living_Expenses, :Savings, :Interest_Rate, :Inflation, :Mich_present,
:Overseas_trip, :Mark_reno, :D_leave_owed_in_days, :D_TLS_shares, :M_TLS_shares, :D_CBA_shares,
:TLS_price, :CBA_price, :Overseas_trip_date, :Mark_reno_date, :Sell_shares
:TLS_price, :CBA_price, :Overseas_trip_date, :Mark_reno_date, :Sell_shares, :CBA, :TLS
)
''', data['vars'])
cset_id = cur.lastrowid