Hi, Everyone,
I have a file test.sql
------------------------------------------------------
ceate or replace procedure test_proc
as
begin
execute immediate 'create table test (id number)';
end
------------------------------------------------------
in my perl, I run it as follows:
my $max_callid_file = "/home/cshao/test/test.sql";
my $sql;
open MAX_CALLID,$max_callid_file||die "error";
while (<MAX_CALLID>)
{
my $max_callid = $_;
$sql = $sql.$max_callid;
}
close MAX_CALLID;
$dbh->do($sql);
which works fine
but after I wrap it,
[cshao@beltway ~/test]$ wrap iname=test.sql oname=test.plb
PL/SQL Wrapper: Release 8.1.7.3.0 - Production on Sun Jul 14 22:42:55 2002
Copyright (c) Oracle Corporation 1993, 2000. All Rights Reserved.
Processing test.sql to test.plb
The same script
my $max_callid_file = "/home/cshao/test/test.plb";
my $sql;
open MAX_CALLID,$max_callid_file||die "error";
while (<MAX_CALLID>)
{
my $max_callid = $_;
$sql = $sql.$max_callid;
}
close MAX_CALLID;
$dbh->do($sql);
I got the following error
[cshao@beltway ~/test]$ ./test.pl
Can't mix placeholder styles (:1/:foo) at
/usr/local/lib/perl5/site_perl/5.6.0/sun4-solaris/DBD/Oracle.pm line 293.
Is there any way I can run a wrapped sql statement from DBI?
Thanks for your help.