More ledger work. Now is adding a ledger entry with an expense and account entry. Found a logic issue for entering expenses with a date before the latest. Exploring options and solutions. Wrote a few more queries to handle retrieving information from the db.