Hey Haikuo Thanks for the quick answer. I will try and answer your questions: 1) The first dataset is presorted by Ticker The second and thirt dataset is presorted by date(year) 2) Each Ticker-Year observation is unique in each dataset, so no dublicates. 3) I only want the observations, that have an value in x y and z, after i have merged the dataset. 4) Ticker Year Value Ticker Year Value Ticker Year Value OUTPUT ==> Ticker Year X Y Z AA 1990 X1 AA 1990 Y1 AA 1990 Z1 AA 1990 X1 Y1 Z1 AA 1991 X2 AA 1991 Y2 AA 1992 X3 Simple example, i have a lot of observations for each ticker in different years, but the Ticker-YEAR combinations are not the same in each dataset. 5) Don't understand, should i add by statement instead of if? Happy Holidays!
... View more