LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous (more recent) messageNext (less recent) messagePrevious (more recent) in topicNext (less recent) in topicPrevious (more recent) by same authorNext (less recent) by same authorPrevious page (October 1997, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Wed, 15 Oct 1997 15:43:55 -0400
Reply-To:     RICHARD STEVENS <RSTEVENS@BCBSCT.COM>
Sender:       "SAS(r) Discussion" <SAS-L@UGA.CC.UGA.EDU>
From:         RICHARD STEVENS <RSTEVENS@BCBSCT.COM>
Subject:      Proc Transpose

Hi all,

This probably has a simple solution, but I can't seem to see it. The bottom line is I want the the results to have one COL1 not more than one. I have tried this on MVS v6.09 and MS Windows 3.1, SAS 6.11 and get the same results. The manual example shows that this is possible, but using the example, I don't get the results. (SAS Procedures Guide v6 3rd ed p597).

The files and code follow:

SAS data -- mccc1.pds OBS MBRNM1 MBRNM2 MBRNM3 MBRNM4 MBRNM5 MBRNM6 . . .

1 @JOBX951 @JOB01X @JOB02 CHCMEMRL CLMX01 CLM01 2 SEASONT1 SEASON01 SEASON02 SEASON03 SEASON99 TEMP01

MBRNM10 MBRNM11 MBRNM12 MBRNM13 DSNAME

EMUC03 EMUC04 FORMAT HEDISCL A438U11.CONTAIN.CODE A438U11.CONTAIN.CODE

I tried rearranging the variables to see if that helped, it didn't. proc sql; create table work.pdsin as select dsname,mbrnm1,mbrnm2,mbrnm3,mbrnm4,mbrnm5,mbrnm6,mbrnm7 ,mbrnm8,mbrnm9,mbrnm10,mbrnm11,mbrnm12,mbrnm13 from mccc1.pds ;

proc transpose data=work.pdsin out=mccc1.pdstrn let; by dsname; var mbrnm1-mbrnm13; run;

The output: I would like to see the values under _NAME_ repeated with the values COL2, therefore no COL2 or greater in the out file. OBS DSNAME _NAME_ COL1 COL2

1 A438U11.CONTAIN.CODE MBRNM1 @JOBX951 SEASONT1 2 A438U11.CONTAIN.CODE MBRNM2 @JOB01X SEASON01 3 A438U11.CONTAIN.CODE MBRNM3 @JOB02 SEASON02 4 A438U11.CONTAIN.CODE MBRNM4 CHCMEMRL SEASON03 5 A438U11.CONTAIN.CODE MBRNM5 CLMX01 SEASON99 6 A438U11.CONTAIN.CODE MBRNM6 CLM01 TEMP01 7 A438U11.CONTAIN.CODE MBRNM7 CONTENTS TSODB2C 8 A438U11.CONTAIN.CODE MBRNM8 EMUC01 9 A438U11.CONTAIN.CODE MBRNM9 EMUC02 10 A438U11.CONTAIN.CODE MBRNM10 EMUC03 11 A438U11.CONTAIN.CODE MBRNM11 EMUC04 12 A438U11.CONTAIN.CODE MBRNM12 FORMAT 13 A438U11.CONTAIN.CODE MBRNM13 HEDISCL

Thanks for you assistance. Richard


Back to: Top of message | Previous page | Main SAS-L page