From: Richard A. DeVenezia on
On May 12, 6:01 am, Amar Mundankar <amarmundan...(a)gmail.com> wrote:
> Hi All,
> There are 2 libraries SD2 and PREV.
>
> I have copied all the datasets from SD2 to PREV using PROC DATASETS.
> I used the following code.
> PROC DATASETS LIB = SD2 NOLIST;
>         COPY IN = SD2 OUT = PREV;
> QUIT;
> I did not use  the MEMTYPE = option , so ideally it should copy
> DATA,VIEW and INDEX.
>
> Generally PROC DATASETS copies the dataset along with indexes
> associated with that dataset.
> But i didnt see any index in PREV library.
>
> Now I have to copy (not move) all the indexes present in SD2 library
> to PREV.
> I tried the follwoing code. But it didnt work.
>
> PROC DATASETS LIB = SD2 NOLIST MEMTYPE = INDEX;
>         COPY IN = SD2 OUT = PREV;
> QUIT;
>
> Any Idea??

Amar:

You will probably have to recreate the indices (hopefully you have the
original code for that), or redo the copy using Proc MIGRATE.

--
Richard A. DeVenezia


From: Amar Mundankar on
On May 12, 7:20 pm, "Richard A. DeVenezia" <rdevene...(a)gmail.com>
wrote:
> On May 12, 6:01 am, Amar Mundankar <amarmundan...(a)gmail.com> wrote:
>
>
>
>
>
> > Hi All,
> > There are 2 libraries SD2 and PREV.
>
> > I have copied all the datasets from SD2 to PREV using PROC DATASETS.
> > I used the following code.
> > PROC DATASETS LIB = SD2 NOLIST;
> >         COPY IN = SD2 OUT = PREV;
> > QUIT;
> > I did not use  the MEMTYPE = option , so ideally it should copy
> > DATA,VIEW and INDEX.
>
> > Generally PROC DATASETS copies the dataset along with indexes
> > associated with that dataset.
> > But i didnt see any index in PREV library.
>
> > Now I have to copy (not move) all the indexes present in SD2 library
> > to PREV.
> > I tried the follwoing code. But it didnt work.
>
> > PROC DATASETS LIB = SD2 NOLIST MEMTYPE = INDEX;
> >         COPY IN = SD2 OUT = PREV;
> > QUIT;
>
> > Any Idea??
>
> Amar:
>
> You will probably have to recreate the indices (hopefully you have the
> original code for that), or redo the copy using Proc MIGRATE.
>
> --
> Richard A. DeVenezia- Hide quoted text -
>
> - Show quoted text -

Hi Richard,
Actually I was trying to copy in Windows SAS. But when I used the same
code (i.e. using PROC DATASETS) , indexes along with the Datasets were
copied to the PREV directory.

Thanks for your reply...

Cheers..

Regards,
Amar Mundankar.