Date: Thu, 24 Jan 2002 23:38:05 +0000
Reply-To: Jon Bodfish <jbodfish@URREA.ORG>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Jon Bodfish <jbodfish@URREA.ORG>
Organization: Mailgate.ORG Server - http://www.Mailgate.ORG
Subject: Insert into a proc sql/ sql server
Content-Type: text/plain; charset=ISO-8859-1
Hello,
Unfortunately, I am experiencing some trouble when loading SAS data from
proc sql into a SQL Server (SQL 2000) table. After submitting the
statements listed below my log states the following: "[ODBC SQL Server
Driver][SQL Server]Cannot insert explicit value for identity column in
table 't_PAT_patients' when IDENTITY_INSERT is set to OFF"
libname a odbc dsn=TestBase;
proc sql;
insert into a.t_PAT_Patients (PAT_RACE)
select PAT_RACE from WWDPat;
But PAT_RACE is not an identity column in t_PAT_Patients. However, if I
upload the SAS dataset to a junk table in SQL server, then run the same
insert either from proc dbload or direcly in SQL then I do not
experience any problems.
Thanks for you help in advance.
--
Posted via Mailgate.ORG Server - http://www.Mailgate.ORG