How can I calculate a column based on data from two different data tables?
I am trying to do some basic math on two different data sets.
I have one data table that has oil production numbers per year for a list of companies.
I have a second data table that has cost per year for the same set of companies.
The data tables are related by the company name (ID #).
I would like to divide the cost per year by the production per year for each company.
In my mind, this simple math would be: Cost per bbl of production = Cost per year ( data table 2) / Production per year (data table 1) .
This seems like a simple thing to do but I cant figure out how to insert a calculated colum using metrics from two different data tables. Can somebody give me a hand?