# Combining data

#### luckyb

##### New Member
Hello,
I have two datasets and would like to add data from variable 'newvar', included in dataset Y, to dataset X. The data from 'newvar' would have to be in matching rows determined by a variable 'row_number'. The tables would look like something like this, but with such a large amount of data that doing it all manually would be tiresome.

Y
Code:
row_number newvar
2 0
3 1
6 1
8 0

Code:
row_number
1
2
3
4
5
6
7
8
9