Chapter Contents |
Previous |
Next |
ATTRC |
Category: | SAS File I/O |
Syntax | |
Arguments | |
Examples | |
See Also |
Syntax |
ATTRC(data-set-id,attr-name) |
Valid values for use with attr-name are:
CHARSET
empty string | Data set not sorted |
ASCII | ASCII character set |
EBCDIC | EBCDIC character set |
ANSI | OS/2 ANSI standard ASCII character set |
OEM | OS/2 OEM code format |
ENCRYPT
ENGINE
LABEL
LIB
MEM
MODE
I | INPUT mode allows random access if the engine supports it; otherwise, it defaults to IN mode. |
IN | INPUT mode reads sequentially and allows revisiting observations. |
IS | INPUT mode reads sequentially but does not allow revisiting observations. |
N | NEW mode creates a new data set. |
U | UPDATE mode allows random access if the engine supports it; otherwise, it defaults to UN mode. |
UN | UPDATE mode reads sequentially and allows revisiting observations. |
US | UPDATE mode reads sequentially but does not allow revisiting observations. |
V | UTILITY mode allows modification of variable attributes and indexes associated with the data set. |
MTYPE
SORTEDBY
SORTLVL
Empty string | Data set is not sorted. |
WEAK | Sort order of the data set was established by the user (for example, through the SORTEDBY data set option). The system cannot validate its correctness, so the order of observations cannot be depended on. |
STRONG | Sort order of the data set was established by the software (for example, through PROC SORT or the OUT= option in the CONTENTS procedure). |
SORTSEQ
TYPE
Examples |
%let mode=%sysfunc(attrc(&dsid,MODE)); %if &mode ne IS %then %put Data set has not been opened in INPUT SEQUENTIAL mode.;
data _null_; dsid=open("sasdata.sortcars","i"); charset=attrc(dsid,"CHARSET"); if charset = "" then put "Data set has not been sorted."; else put "Data set sorted with " charset "character set."; rc=close(dsid); run;
See Also |
Functions:
|
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.