Hi
You could use a 'modify' statement (data step). This statement does
the changes in place and needs therefore only have of the space, BUT:
there is a risk of corrupting your data; look it up in the manual.
I also think that some re-designing could solve some problems and
improve performance. I assume you're loading kind of a data mart with
a history of 24 months.
What you could do (just an idea):
- Create a SAS file per month (eg: prod.master_date&yyyymm)
- Create a SAS view for the most recent 24 SAS files (prod.master).
- Create an index over the date field.
Advantages:
- Loading of new data will be much faster (create new file with
current month, re-create view, delete SAS file with data older 24
months).
- As the SAS view has the same name like previously the SAS data file
your users won't even get that something changed (assuming they only
read the data).
- Queries using the index will perform much faster.
- SAS powerusers can also be told the new data organisation and they
can query the monthly files directly
- Smaller files are also much better to handle for backup & recovery
processes.
HTH
Patrick