Microsoft KB Archive/271494

= How To Send Batch SQL Statements to Oracle =

Article ID: 271494

Article Last Modified on 7/13/2004

-

APPLIES TO


 * Microsoft Data Access Components 1.5, when used with:
 * the hardware: Intel x86
 * Microsoft Data Access Components 2.0, when used with:
 * the hardware: Intel x86
 * Microsoft Data Access Components 2.1, when used with:
 * the hardware: Intel x86
 * Microsoft Data Access Components 2.1 Service Pack 2, when used with:
 * the hardware: Intel x86
 * Microsoft Data Access Components 2.1 Service Pack 1, when used with:
 * the hardware: Intel x86
 * Microsoft Data Access Components 2.1 Service Pack 2, when used with:
 * the hardware: Intel x86
 * Microsoft Data Access Components 2.5, when used with:
 * the hardware: Intel x86
 * Microsoft Data Access Components 2.6, when used with:
 * the hardware: Intel x86

-



This article was previously published under Q271494



SUMMARY
It is possible to create a batch of SQL statements that run on Microsoft SQL Server by separating each SQL statement with a semicolon. You can achieve similar results when you run Oracle with either the OLE-DB Oracle Provider or Oracle driver (provided with the Microsoft Visual Database Tools) if you create an Oracle Block Structure with the BEGIN and END statements.



MORE INFORMATION
Following is sample code that illustrates the use of BEGIN and END: // Tables Definition create table table1 (fname varchar2(20), lname varchar2(30))

//INSERTS begin insert into table1 values ('John', 'Doe'); Insert into table1 values ('Mary', 'Doe'); end;

