Executing multi-line sql commands via ADO/Oracle drivers [message #199966] |
Fri, 27 October 2006 03:52 |
SemperOnit
Messages: 2 Registered: October 2006 Location: UK
|
Junior Member |
|
|
Hi,
I'm trying to do multiple inserts via my ADOConnection object with the following as my SQL parameter.
"insert into TMP_PORTFOLIO values ('3011');"
i.e. (from VB):
Call adoConnnection.Execute(strSQL)
This works fine but I want to execute more than one insert at a time e.g.
"insert into TMP_PORTFOLIO values ('3021');
insert into TMP_PORTFOLIO values ('3478');"
,where there is a crlf between the statements, I get the following error
"[Oracle][ODBC][Ora]ORA-00911: invalid character".
So I try it wihout the crlfs and just the semi-colons and it still doesn't work. Is it possible to do this? It is fine on Sybase. I guess the Oracle provider is stripping out the crlfs. I don't want to have to loop round an array calling multiple ADO executes.
Here's my provider details Provider=MSDASQL.1;DRIVER=Oracle in OraHome92;
Driver version is 9.02.00.00
Hope someone can help
Thanks
Paul
|
|
|