Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Insert records to AS400 from SQL stored Procedure

Author  Topic 

dhilling
Starting Member

3 Posts

Posted - 2006-06-21 : 15:15:19
I am trying to insert records via Stored Procedure to a single AS400 table. I can read the records from any table just not insert.
here is a basic test I am running which is not working.

works fine:
SELECT CAS,COMP FROM OPENQUERY(DOUHIL,'SELECT CAS,COMP FROM CAS')

crashes:
SELECT * FROM OPENQUERY(DOUHIL,'INSERT INTO CAS(CAS,COMP) VALUES(''222'',''TEST2'')')

any sample statement that work work be great!

Doug

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2006-06-21 : 15:41:12
try openrowset instead.

insert into openrowset...


Peter Larsson
Helsingborg, Sweden
Go to Top of Page
   

- Advertisement -