由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Statistics版 - help on importing csv file to SAS
相关主题
请教如何同时用sas打开多个excel文件?多谢!reading data into sas 问题
questions about SAS import Excel dataProc import 读excel文件,怎么略去前面几行?
Help:import excel file into sas请教:多个csv文件(>100)怎么用"proc sql" merge成一个文件?
SAS的一个小问题再看SAS in stock market 这本书 有啥数据库可以拿来联系的吗
SAS 数据读入的问题 (proc import)怎么把文本文件(TEXT)转到SAS
SAS macro to import multiple csv file??@@请教用SAS import CSV 文件时遇到的状况
SAS date format 的问题SAS不能导入EXCEL2003的数据!
SAS proc import excel file 紧急求助sas importing question
相关话题的讨论汇总
话题: yes话题: csv话题: sas话题: import话题: mixed
进入Statistics版参与讨论
1 (共1页)
E********9
发帖数: 7
1
请教大家一个问题:
I'd like to import several .csv file to SAS, but how come I can't use
statement like
MIXED=YES;
USEDATE=YES;
SCANTIME=YES;
in the proc import procedure?
Here is my code:
proc import datafile="---.csv" out=sasuser.trial dbms=csv replace;
delimiter=",";
getnames=yes;
MIXED=YES;
USEDATE=YES;
SCANTIME=YES;
run;
I'm working on UNIX, so didn't try converting csv files to excel before
importing them. Without the statements mentioned above, I have a lot of
error mes
S******t
发帖数: 1437
2
Can u give a few examples in detail?
In my opinion, proc import is the most convenient way to import csv files
into SAS. But if it doesn't work, you may try data step, that way you can
define each variable to be numerical or character.
E********9
发帖数: 7
3
Thank you for your reply.
Below is the log I got:
proc import datafile="---.csv" out=sasuser.trial dbms=csv replace;
NOTE: The previous statement has been deleted.
NOTE: The previous statement has been deleted.
3 delimiter=",";
4 getnames=yes;
5 MIXED=YES;
-----
180
6 USEDATE=YES;
-------
180
7 SCANTIME=YES;
--------
180
ERROR 180-322: Statement is not valid or it is used out of proper order.
8 run;
I
s*r
发帖数: 2757
4
an extra ;
E********9
发帖数: 7
5
恕我愚钝, where is that extra ; ?
S***e
发帖数: 108
6
MIXED=yes|no,USEDATE=yes|no,SCANTIME=yes|no are options for reading excel
files, not for csv files.
If you want to use those options in SAS, you'd better convert your csv file
to excel file first.
E********9
发帖数: 7
7
That's what I'm wondering.
I'm working on unix so I can't import data in excel files.
Any idea on how to read data stored in csv files like dates in SAS?
y******0
发帖数: 401
8
using Data xx; infile ..;
1 (共1页)
进入Statistics版参与讨论
相关主题
sas importing questionSAS 数据读入的问题 (proc import)
what is the problem?SAS macro to import multiple csv file??
帮我看看如何导入.dat file into sas吧SAS date format 的问题
[合集] excel dataSAS proc import excel file 紧急求助
请教如何同时用sas打开多个excel文件?多谢!reading data into sas 问题
questions about SAS import Excel dataProc import 读excel文件,怎么略去前面几行?
Help:import excel file into sas请教:多个csv文件(>100)怎么用"proc sql" merge成一个文件?
SAS的一个小问题再看SAS in stock market 这本书 有啥数据库可以拿来联系的吗
相关话题的讨论汇总
话题: yes话题: csv话题: sas话题: import话题: mixed