Kbase P10527: How to programmatically perform a Bulk Insert with Oracle DataServer?
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  03/12/2010 |
|
Status: Verified
GOAL:
How to programmatically perform a Bulk Insert with Oracle DataServer?
GOAL:
How to performance bulk load with ABL?
FACT(s) (Environment):
All Supported Operating Systems
Oracle
Oracle DataServer
FIX:
run stored-proc send-sql-statement h1 = proc-handle ("--Bulk-insert Start 10").
close stored-proc send-sql-statement r1 = proc-status where proc-handle = h1.
do i = 1001 to 1040:
create customer.
assign cust-num = i.
assign name = "Bulk cust " + string (i).
if i > 1020 then
comments = "asjkasdjkakjdjaksdjaks jkasdjk".
if i = 1035 then
comments = fill("asdf ", 1000).
end.
release customer. /* Flush out the last one before --Bulk-insert End */
run stored-proc send-sql-statement h2= proc-handle ("--Bulk-insert End").
close stored-proc send-sql-statement r2 = proc-status where proc-handle = h2.
display error-status:error.
display error-status:get-message(1) format "x(60)" error-status:get-number(1).