On Thu, 26 Oct 2006 04:17:34 -0400, Gerhard Hellriegel
>there is no update function in SAS as far as I know.
>I think you mean the update statement, like:
> update a b;
> by var;
>that thing you use instead of SET. You need at least one common key variable
>in a and b (the BY-list) and the other common variables in A are replaced by
>the values in B. If all variables in B are also in A and also A is the ouput
>dataset, SAS can optimize that step and make a real update in place. Both
>must be sorted of course.
I believe that UPDATE will never change a data set in place. If you want
that to happen, use MODIFY instead of UPDATE.
MODIFY does not require that all variables in B are also in A. Of course,
any newly introduced variables are not preserved in the output. But
consider, for example, a DATA step that is supposed to selectively delete
observations from A. B might include a variable DELETE_FLAG to control that.
MODIFY does *not* require that either A or B be either sorted or indexed by
the BY variables. In fact, sorting is a dubious proposition in this
situation, since any new observations will be written to the end of A and
this will generally destroy the sorted-by property. On the other hand,
indexing A can dramatically improve performance.
>On Thu, 26 Oct 2006 00:42:59 -0700, lavanya <lavenskey@GMAIL.COM> wrote:
>>can anyone pls tel me what is the update function in sas