I have a API wrapper that pulls data from a specific product. I am facing this problem of how can I map the json data to the database (postgresql). I have read up on Pandas dataframe but I am unsure if it is the right way to go. I have a few questions that I need help with.
1) Is it possible to choose which rows get into the dataframe?
2) Every row inside the dataframe needs to be inserted into two different database tables. I would need to insert ten columns into TableA get the id of the newly inserted row and insert five columns including the returned id into TableB. How would I go about this?
3) Is it possible to specify the data types for each column in the dataframe?
4) Is it possible to rename the column names to the database field names?
5) Is it possible to iterate through specific columns and replace certain data?
Is there a specific term for what I am trying to accomplish which I can search for?
Many thanks!