My code functions perfectly on the local host with MS Access Database using the specified path. However, during and after the deployment phase, it fails to recognize my database path and does not accept the connection string that includes this path. I kindly request you to review my code and provide the correct code that will enable my MS Access Database to operate successfully after deployment. Thank you in advance for your assistance.
see my code
import streamlit as st
import pyodbc
import pandas as pd
conn_str = ( ‘DRIVER={Microsoft Access Driver (*.mdb, *.accdb)} ; DBQ=.\TESTDB\mfa.accdb;’) # give error
#DBQ=.\TESTDB\mfa.accdb;’) # give error
connm = pyodbc.connect(conn_str)
cursorm = connm.cursor()
query = “SELECT * FROM Payments”
dataf = pd.read_sql(query, connm)
mm = st.dataframe()
st.write(dataf)
see error