Тёмный

2 Scenarios where SAS merge and joins results are not same 

SMARTTECH
Подписаться 9 тыс.
Просмотров 7 тыс.
50% 1

Опубликовано:

 

2 окт 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 16   
@dougdame6706
@dougdame6706 3 года назад
In my experience, a many-to-many merge in SAS almost always is a signal that there's data problems. Here, for example, age for ID=2 in the left-hand dataset is 10 or 20 ... well, which is it? And in the right-hand dataset, ID=2 has a salary of 5000 ... or 6000 or 7000. At any given point in time, person-ID=2's salary has to be one value. So probably/possibly, the right dataset has a date field that should have been used as a filter of some sort, and the programmer didn't know that, or didn't do it. I always interpret a SAS-note warning of a many-to-many merge as saying "Whoa Dummy ... you don't know your data as well as you think you do ... something needs fixing here." Offhand it's hard to envision a situation where what happens in a SAS many-to-many merge is what you WANT to happen, particularly in regard to how it carries (retains) field values into the "extra rows". But other than that, I strongly prefer SAS merges to SQL joins. You have clear control with the IN= vars, and the notes telling you the input and output counts of rows and fields is a tremendous help in auditing that what's happening is what you intended and expected.
@kiranvenna
@kiranvenna 3 года назад
Excellent points. I agree with you on all points.
@Klisania_A
@Klisania_A 3 года назад
Thank you for sharing. It was very helpful to clear the merge concept with same variables. Faced this with three table merge and when I was trying to do same step in Python didn't happened. So SAS was very handy to get the data with merge.
@GKrishnna-c2b
@GKrishnna-c2b 3 года назад
As USUAL nice explanation thanks sirr
@mkrishna2593
@mkrishna2593 Год назад
But in many to many join, you selected only salary column of 2nd table. Why cannot we select * from 2nd table also?
@kiranvenna
@kiranvenna Год назад
Please check out this video to understand in detail. ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-IrgwvhYebww.html
@akshayaseetharaman5687
@akshayaseetharaman5687 9 месяцев назад
Thankyou so much sir.
@vamsikrishnakandagatla7937
@vamsikrishnakandagatla7937 2 месяца назад
Sir thank you for sharing but to do proper merging or joining we need as first explained id, age ,salery 3 records but not should not show the age proper output
@kiranvenna
@kiranvenna 2 месяца назад
Hi, I did not completely understand your question.
@vamsikrishnakandagatla7937
@vamsikrishnakandagatla7937 2 месяца назад
I am asking that if the loglines are there how it will merge... Please
@Toloo.
@Toloo. Год назад
I have never seen the teaching like this, amazing, fabulous, elegent, fantastic, and Thank you so much for sharing your knowledge, I would like to subscribe to your channel one million times, plz go ahead
@kiranvenna
@kiranvenna Год назад
Thank you for your kind words.
@shivampathak5546
@shivampathak5546 2 года назад
You doing a great work 😊
@crystalmaiden7590
@crystalmaiden7590 2 года назад
Very helpful 👌
@bharathkumarkambala5575
@bharathkumarkambala5575 3 года назад
Very helpful
@9356079
@9356079 2 года назад
Thank ypu
Далее
ETL with SAS - some Basics and Optimizations
15:56
Просмотров 22 тыс.
Как открыть багажник?
00:36
Просмотров 16 тыс.
Proc SQL part 5 - Joins (Detailed 50 Min long video)
49:48
PROC SQL part -1 Basic syntax select and others
21:58
WHERE vs AND in a Proc SQL left join
13:09
Просмотров 3,8 тыс.
SAS Tutorial | Mastering the WHERE Clause in PROC SQL
24:15