Hi data _null_
SCD2: That's mainly nothing else than a loading technique where you keep all the history records in the same table - which means that these tables tend to grow.
http://en.wikipedia.org/wiki/Slowly_changing_dimension
Less of an issue if someone uses a data base like Oracle where a table can be partitioned; more of an issue with SAS files where a table is just one big file.
You really pushed me into the right direction. I think I found everything I need in the docu:
http://support.sas.com/documentation/cdl/en/lrcon/62955/HTML/default/viewer.htm#/documentation/cdl/e...
As I have to use SAS DI Studio in the project I am the only option will be to use an audit trail.
That's the approach I have in mind:
proc datasets lib=work nolist;
audit want;
initiate ;
LOG
BEFORE_IMAGE=NO
DATA_IMAGE=NO
ERROR_IMAGE=YES;
run;
quit;
proc append base=want data=have;
run;
data error_yymmdd;
set want(type=audit keep=id _:);
run;
proc datasets lib=work nolist;
audit want;
TERMINATE ;
run;
quit;
For the ones using DI Studio 4.2:
I'm thinking about implementing the part before the PROC APPEND as pre-code in the SCD2 loader, and the part after the PROC APPEND as post-code.
Thanks
Patrick