I have a table which contains information of an equipment location (where the equipment is installed as per Area and Sub-Area) sample of table is here. LocationId is the unique key.
enter image description here
Now to track the movement of the area, I have created another table having the transaction details from which location to which location the equipment is moved.
enter image description here
How to form a table/view like this
|Area Old Location |Sub-Area Old Location |Area New Location | Sub-Area New Location | Transaction Date |
I tried few combination of join, but I couldn’t do.
I tried join command two times but it is not working for me.