Syntrex commited on
Commit
851b5bb
·
verified ·
1 Parent(s): b351835

Update database/db.py

Browse files
Files changed (1) hide show
  1. database/db.py +11 -1
database/db.py CHANGED
@@ -385,4 +385,14 @@ def insert_batter_prop_outcomes(conn, df: pd.DataFrame) -> None:
385
  SELECT * FROM batter_prop_outcomes_df
386
  """
387
  )
388
- conn.unregister("batter_prop_outcomes_df")
 
 
 
 
 
 
 
 
 
 
 
385
  SELECT * FROM batter_prop_outcomes_df
386
  """
387
  )
388
+ conn.unregister("batter_prop_outcomes_df")
389
+
390
+ def read_batter_prop_outcomes(conn) -> pd.DataFrame:
391
+ ensure_batter_prop_outcomes_table(conn)
392
+ return conn.execute(
393
+ """
394
+ SELECT *
395
+ FROM batter_prop_outcomes
396
+ ORDER BY graded_at DESC, created_at DESC
397
+ """
398
+ ).df()