proc transpose data=prep_suppae out=trans
name=QNAM label=Qlabel;
by USUBJID IDVAR IDVARVAL QORIG ;
var StID CRFID;
run;
Should have the labels for Stid and CRFid in a variable named Qlabel, IF the variables have a label assigned.
Here is a brief example with other data:
proc sort data=sashelp.class out=work.class;
by sex age;
run;
proc transpose data=work.class
name=qname label=qlabel;
by sex age;
var height weight;
label height='Height at age'
weight='Weight at age'
;
run;
The Sashelp.class data set does not have any variable labels assigned and hence no value for qlabel without them. Putting a label statement in the transpose code makes them available for the step to demonstrate the result. If only one of the variables has a label only those rows of the output have a value for qlabel.
If you are wanting labels for other variables we'll need more information and possibly example data.