Date: Mon, 17 Jan 2000 12:31:55 -0500
Reply-To: David Ward <dward@SASHELP.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: David Ward <dward@SASHELP.COM>
Subject: Strange values using SCL append function
I am using the append function like this (simplified code):
dsid=open('my dataset(where=(my where clause))','U');
if not(attrn(dsid,'ANY')) then do;
call putvarn(dsid,my numeric var);
call putvarc(dsid,my character var);
I am checking to see if a record exists in my data set that meets a certain criteria. If it does not exist, I want to create it - seems simple enough. The problem I'm having is that I am not specifically putting values into each of the variables in my data set. I assumed that the variables I did not use a putvar on would be set to missing in my new record but they were not. The numeric variables are being set to 0 and the character variables are being set to a string of null characters (ASCII code 00).
Why is this happening? Do I have a fundamental misunderstanding of the DDV and how/when values are placed into it?
One more note: I'm not using a call set on the data set.