楼主: fishsil
1361 1

关于eof、eov及end? [推广有奖]

  • 0关注
  • 0粉丝

大专生

15%

还不是VIP/贵宾

-

威望
0
论坛币
50 个
通用积分
0
学术水平
0 点
热心指数
1 点
信用等级
0 点
经验
773 点
帖子
48
精华
0
在线时间
25 小时
注册时间
2012-11-5
最后登录
2015-7-29

+2 论坛币
k人 参与回答

经管之家送您一份

应届毕业生专属福利!

求职就业群
赵安豆老师微信:zhaoandou666

经管之家联合CDA

送您一个全额奖学金名额~ !

感谢您参与论坛问题回答

经管之家送您两个论坛币!

+2 论坛币
关于这三个实在看不懂在infile中怎么用?请大神举例指教。。。。。。
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

关键词:End infile file NFI 看不懂

沙发
wpfwxn 发表于 2015-2-13 10:13:45 |只看作者 |坛友微信交流群
END=variable
specifies a variable that SAS sets to 1 when the current input data record is the last in the input file. Until SAS processes the last data record, the END= variable is set to 0. Like automatic variables, this variable is not written to the data set.
Restriction:You cannot use the END= option with the UNBUFFERED option, the DATALINES or DATALINES4 statement, or an INPUT statement that reads multiple input data records.
Tip:Use the option EOF= when END= is invalid.
Example:Reading from Multiple Input Files
EOF=label
specifies a statement label that is the object of an implicit GO TO when the INFILE statement reaches end of file. When an INPUT statement attempts to read from a file that has no more records, SAS moves execution to the statement label indicated.
Interaction:Use EOF= instead of the END= option with the UNBUFFERED option, the DATALINES or DATALINES4 statement, an INPUT statement that reads multiple input data records.
Tip:The EOF= option is useful when you read from multiple input files sequentially.
See:END=, EOV=, and UNBUFFERED
EOV=variable
specifies a variable that SAS sets to 1 when the first record in a file in a series of concatenated files is read. The variable is set only after SAS encounters the next file. Like automatic variables, the EOV= variable is not written to the data set.
Tip:Reset the EOV= variable back to 0 after SAS encounters each boundary.
See:END= and EOF=
EXPANDTABS | NOEXPANDTABS

结合示例看,更有体会

使用道具

您需要登录后才可以回帖 登录 | 我要注册

本版微信群
加好友,备注cda
拉您进交流群

京ICP备16021002-2号 京B2-20170662号 京公网安备 11010802022788号 论坛法律顾问:王进律师 知识产权保护声明   免责及隐私声明

GMT+8, 2024-4-26 21:51