BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
GoBrewers14
Calcite | Level 5

I have two data sets that look like this

1)

========================================

ColumnA     ||  ColumnB     ||  ColumnC     ||  Column D

========================================

     x                    x                    x                    .

     y                    y                    .                    y

     z                    z                    .                    z

and 2)....

========================================

ColumnA     ||  ColumnB     ||  ColumnC     ||  Column D

========================================

     x                    x                    .                    x

     y                    y                    y                    .

     z                    z                    z                    .

I have missing values in the last two columns in each data set.  I want to merge (1-to-1) the two data sets and I want the values from table 1 to go in the cells with the missing values in table 2 and the values in table 2 to go into the cells with missing values in table 1.  I tried to use MERGE but this one-to-one match replaces all columns with just the columns from the 2nd data set which just ends up being the same thing.  Any ideas?

Thank you.

-john

1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User

Look into an update rather than a merge or join.

View solution in original post

2 REPLIES 2
Reeza
Super User

Look into an update rather than a merge or join.

GoBrewers14
Calcite | Level 5

Rezza-

I think this is what I am looking for.  Thank you.

-John

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 744 views
  • 0 likes
  • 2 in conversation