BookmarkSubscribeRSS Feed
Midi
Obsidian | Level 7

Hello Everyone , I have This Table :

 

OssClient_IDCode_ID                
12389551723895517                
22389551723895518       

 

.      .
32389551723895519        .      .
42389551723895520        .       
52389552223895521   

 

 

 

  .      .
62389552223895522        .      

 

 

(425630 ROWS , 3 COLUMN)

Than I have This Other Table :

 

 

 

OssCode_IDType_IDMas          TR_IDLP-i_ID   
1238955171435      

 

   02   
2238955181438       .  00  .
3238955191433    

 

  .  00  .
4238955201415       .  00   
5238955211398       .  00  .
6238955221391       .  00  

 

(5 COLUMNS , 20540 ROWS)

And This Table :

 

OssFAM_IDDes                
130FAT        .       
225MO       

 

.      .
315CH       

 

.      .
415GRA        .

 

      
515MO      

 

 

 

.      .
626FAT     

 

  .      .

(2 Columns , 24510 rows)

 

And This Table

 

OssTYPE_IDDESFAM_ID   

 

 

           
1143FAT50      

 

        
2143MO83       .      .
3143CH38       .      .
4141MO2       .       
5139MO83       .      .
6139GRA19       .      .

 

(3 Columns 24510 Rows )

 

And This is The Table That I want to get :

 

OssClient_IDCode_IDType_IDMasFAM_ID             
12389551723895517143530

 

    .       
22389551723895518143825     .       
32389551723895519143315             
42389551723895520141515     .       
52389552223895521139815     .      .
62389552223895522139126     .    

 

 .

 

So , If anyone can Give me a Help , it would be Great , Thank you in advance.

2 REPLIES 2
Haris
Lapis Lazuli | Level 10
Dude, what, exactly, are you trying to accomplish? You'll need to merge tables pair by pair but how to do that depends on what you need to do.
bknitch
Quartz | Level 8

You could perform a simple Proc Sql and join to the associated tables but it appears your identifiers are not unique to values. Meaning TYPE_ID which is your key is not unique to one FAM_ID or DES on your 3rd (T3) and 4th (T4) table so you will get a 1 to many relationship. In order for this to work you would need T3.FAM_ID = T4.FAM_ID by T3.DES = T4.DES and utilize T3.TYPE_ID = T2.TYEP_ID. Unless these values do equal each other somewhere on your table and are not included on your sample I don't think this will work. 

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

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
  • 478 views
  • 0 likes
  • 3 in conversation