Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Header & detail record

Status
Not open for further replies.

saqi2000

Programmer
Apr 11, 2002
84
GB
Hi guys,

I have a sas program which is suppose to generate a data file. it is generating data file but it's overwriting header record with detail record.

That's what I have in my data _NULL_ section:
line -0;
if first.lineno then;
do;
Put @1 centre
@12 centname;
put @1 formid z5.;
put @1 sub_code
@5 sun_name;
put @1sub_level
@71level_des;
end;

/*Detail record*/
put @1 student_number
@10 sname
@ 71 when_changed
@89 username
@109 change_type;
run;

as i said above it out puts header record and then overwrite it with detail record instead taking a new line after writing the header record.

Please help.

Saqi
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top