BookmarkSubscribeRSS Feed
laxmanpai
Calcite | Level 5

Hi,

 

How do we keep only the active records using SCD Type2 in every run ?.

 

Eg : I execute the job today using SCD type 2 and load into the target table.

 

Tomorrow when I rerun the same job, I should have only the current active records excluding the others. Is there any changes that can be done in SCD type 2 transformation ?

4 REPLIES 4
laxmanpai
Calcite | Level 5

I have not recieved any reply

jennifert
SAS Employee

Hi @laxmanpai ,

Is this maybe a question for the SAS Data Management community rather than SAS Studio?

 

thanks,

Jennifer


Catch the SAS Global Forum keynotes, announcements, and tech content!
sasglobalforum.com | #SASGF

Patrick
Opal | Level 21

@laxmanpai wrote:

Hi,

 

How do we keep only the active records using SCD Type2 in every run ?.

 

Eg : I execute the job today using SCD type 2 and load into the target table.

 

Tomorrow when I rerun the same job, I should have only the current active records excluding the others. Is there any changes that can be done in SCD type 2 transformation ?


To get answers faster ask DIS questions in the Data Management Forum.

As for your question: Type 2 tables keep the full change history so you won't get rid of old records but you expire them. If you want to maintain such a table then yes, the SCD Type 2 transformation can help you with this.

If you always have a full load from source (not deltas) then there is an option somewhere which let's you choose something like "close out records in target but not in source".

Patrick
Opal | Level 21

@laxmanpai 

You haven't provided any feedback. Is your question answered?

sas-innovate-white.png

Our biggest data and AI event of the year.

Don’t miss the livestream kicking off May 7. It’s free. It’s easy. And it’s the best seat in the house.

Join us virtually with our complimentary SAS Innovate Digital Pass. Watch live or on-demand in multiple languages, with translations available to help you get the most out of every session.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 4 replies
  • 1217 views
  • 0 likes
  • 3 in conversation