SAS Component Language Dictionary |
Deletes a row from a SAS table
-
sysrc
-
contains the return code for the operation:
0 |
successful |
0 |
not successful |
Type:
Numeric
-
table-id
-
is the identifier that was assigned when
the SAS table was opened. If table-id is invalid,
the program halts.
Type: Numeric
You must fetch a row before it can be deleted. Some
functions that fetch a row include FETCH, FETCHOBS, LOCATEC, LOCATEN, APPEND,
DATALISTC, and DATALISTN.
Delete the current row from an open SAS table. (The
example assumes that the table identifier returned by the OPEN function was
stored in the SCL variable MYDATAID.) If the function is unable to delete
the row, a message is displayed on the message line.
if (delobs(mydataid)) then _msg_=sysmsg();
APPEND
DATALISTC and DATALISTN
FETCH
FETCHOBS
LOCATEC and LOCATEN
Copyright © 2009 by SAS Institute Inc., Cary, NC, USA. All rights reserved.