I’m new to Streamlit and it’s awesome so far. However, I feel I’ve reached the limit of what I am capable of without asking for help. My requirement is a simple one, but it seems it falls outside of the capabilities of the components and how they work currenlty. I feel I’m asking that bit too much…
Basically, I have some contacts in a database, and I want to record whether they have either paid and/or attended an event by adding two columns into a table (or grid) as shown in the example below. I already have the data in a table, no issues, it’s just adding the controls in to two columns at the end of the table that I need. And possibly how to update records in the database, although I’m confident that once I get over this initial hurdle I’ll be able to figure that bit out.
I’ve looked at columns, tables and aggrid so far, but it’s getting over my head. Am I missing something simple here, or should I move on to something that’s not Streamlit that would better suit my needs?
This is brilliant! Exactly what I needed, thank you very much.
For saving the resulting changes to the database, would I iterate throguh the data in new_data and write each change to the database, or is there a more efficient way? One thing I’m noticing is that for every 10 lines of code in .Net (I’m used to .Net development), there is a single line in Python!! Old habits die hard.
Hey, thanks again. That works, but it’s adding lots of duplicate entires into the database. I think I’m missing a fundamental understanding of how Streamlit works at this point. I just want to commit the entries in the upadated data (diff) dataframe and reload the page, yet the dataframe keeps getting bigger the more changes I add.