Procedure Features: |
PROC
CONTENTS |
PROC DATASETS statement option:
|
MODIFY statement
|
|
CONTENTS statement | |
|
The following
example deletes all labels and formats within a data set.
|
options ls=79 nodate nocenter;
title; |
|
proc format;
value clsfmt 1='Freshman' 2='Sophmore' 3='Junior' 4='Senior';
run; |
|
data class;
format z clsfmt.;
label x='ID NUMBER'
y='AGE'
z='CLASS STATUS';
input x y z;
datalines;
1 20 4
2 18 1
; |
|
proc contents data=class;
run; |
The CONTENTS Procedure
Data Set Name WORK.CLASS Observations 2
Member Type DATA Variables 3
Engine V9 Indexes 0
Created Friday, May 25, 2007 10:26:08 AM Observation Length 24
Last Modified Friday, May 25, 2007 10:26:08 AM Deleted Observations 0
Protection Compressed NO
Data Set Type Sorted NO
Label
Data Representation WINDOWS_32
Encoding wlatin1 Western (Windows)
Engine/Host Dependent Information
Data Set Page Size 4096
Number of Data Set Pages 1
First Data Page 1
Max Obs per Page 168
Obs in First Data Page 2
Number of Data Set Repairs 0
File Name C:\DOCUME~1\mydir\LOCALS~1\Temp\SAS Temporary
Files\_TD3964\class.sas7bdat
Release Created 9.0201B0
Host Created XP_PRO
Alphabetic List of Variables and Attributes
# Variable Type Len Format Label
2 x Num 8 ID NUMBER
3 y Num 8 AGE
1 z Num 8 CLSFMT. CLASS STATUS
|
proc datasets lib=work memtype=data;
modify class;
attrib _all_ label=' ';
attrib _all_ format=;
run; |
|
contents data=class;
run;
quit; |
The DATASETS Procedure
Data Set Name WORK.CLASS Observations 2
Member Type DATA Variables 3
Engine V9 Indexes 0
Created Friday, May 25, 2007 10:26:08 AM Observation Length 24
Last Modified Friday, May 25, 2007 10:26:08 AM Deleted Observations 0
Protection Compressed NO
Data Set Type Sorted NO
Label
Data Representation WINDOWS_32
Encoding wlatin1 Western (Windows)
Engine/Host Dependent Information
Data Set Page Size 4096
Number of Data Set Pages 1
First Data Page 1
Max Obs per Page 168
Obs in First Data Page 2
Number of Data Set Repairs 0
File Name C:\DOCUME~1\mydir\LOCALS~1\Temp\SAS Temporary
Files\_TD3964\class.sas7bdat
Release Created 9.0201B0
Host Created XP_PRO
Alphabetic List of Variables and Attributes
# Variable Type Len
2 x Num 8
3 y Num 8
1 z Num 8
Copyright © 2010 by SAS Institute Inc., Cary, NC, USA. All rights reserved.