Displaying ID and corresponding name in a CRUD app

Hello everyone,
I require assistance with my CRUD app developed using Streamlit. Specifically, I want to add a record using the primary key from another table. I need to input the ID, but I also want to display the corresponding name associated with that ID. It’s important for the user to see both the ID and its corresponding name. Do you have any ideas or suggestions on how I can achieve this? Thank you.