• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 259
  • Last Modified:

execute pl/sql block from perl program

can you please provide guidance with code examples on executing a pl/sql block with input values from a perl program?

thanks
0
eagle_ea
Asked:
eagle_ea
  • 2
1 Solution
 
wilcoxonCommented:
You want to look at the DBI and DBD::Oracle modules.
0
 
eagle_eaAuthor Commented:
assuming that is already in place, can you post an example of the code?
0
 
wilcoxonCommented:
I don't personally use Oracle and don't have time to post multiple detailed examples but this is the basic flow.  What sorts of PL/SQL blocks do you want to execute (it's very hard to come up with examples without more details).
use strict;
use warnings;
use DBI;
my $dbh = DBI->connect('oracle...');
$dbh->do("some PL/SQL block that does not return values");
my $ret = $dbh->selectall_arrayref("some PL/SQL block that does return values");

Open in new window

For more complicated things, you can also look at statement handles.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: Microsoft Windows 7 Basic

This introductory course to Windows 7 environment will teach you about working with the Windows operating system. You will learn about basic functions including start menu; the desktop; managing files, folders, and libraries.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now