Re: modules

2002-01-08 Thread Carlin Anderson

Does it matter what version of perl is currently running (I am on 5.61), and 
are there any concerns on using the automatic installation process against a 
production environment?  Does the automatic process pick the right version 
of the module based on what is already installed?

Thanks

Carlin


Original Message Follows
From: [EMAIL PROTECTED]
To: TS [EMAIL PROTECTED]
CC: [EMAIL PROTECTED]
Subject: Re: modules
Date: Fri, 5 Oct 2001 12:27:27 +0200 (CEST)

On Fri, 5 Oct 2001, TS wrote:

  I use perl 5.005_03.
  how do I find out what modules are installed ?

$perl -MCPAN -e autobundle
This will first search for all installed module. Then it will search the
cpan archive for updates...
Perhaps you need answere a few question if this is the very first time you
connect to CPAN. But it's easy. Just do it:-)

  and how do I add new modules ?(where are they
  available?).

$perl -e MCPAN -e 'install MODUL_NAME::xxx'

this will search the archive after module namedd MODUL_NAME::xxx and
install it. If this module need other modules to work ok. The installation
prossess will automatic fix this.


Karl


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


_
Chat with friends online, try MSN Messenger: http://messenger.msn.com


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Oracle function- Error when attempting call. Please Help !

2001-08-28 Thread Carlin Anderson

Does anyone have an example of how to set up and call an oracle function
that returns a number?  Embedding within an sql statement as I normally
use a query does not work, and I receive errors if I attempt to format
it like an example in the dbd document:


Here is a section of my code.

my $catalog=SMB;
my $code=$info-{.code};
my $itemid=10501076150130;
my $dbh = DBI-connect('DBI:Oracle:ORCL','a', 'b')
or die Couldn't connect to database:  .
DBI-errstr;
my $sth = $dbh-prepare(SELECT item_owner FROM item where item_id =
'$catalog$itemid')
or die Couldn't prepare statement:  .
$dbh-errstr;
my $qty;
my @data;
$sth-execute() # Execute the query
or die Couldn't execute statement:  . $sth-errstr;
(@data) = $sth-fetchrow;
$qty = @data[2];
print data returned = @data\n;

  $sth = $dbh-prepare(BEGIN :result = getpickableqty(:id) END;);
  $sth-bind_param(:id, $catalog$itemid);
  my ($result) = 0;
  $sth-bind_param_inout(:result,  \$result,  100);
  $sth-execute();
  print func_name returned '$result' \n;


Results of the program is this:

data returned = SMB10501076150130   *  The
regular SQL works ok  **
DBD::Oracle::st execute failed: ORA-06550: line 1, column 15:
PLS-00103: Encountered the symbol = when expecting one of the
following:

   := . ( @ % ; indicator
ORA-06550: line 1, column 37:
PLS-00103: Encountered the symbol END when expecting one of the
following:

   . ( * %  - + ; / at mod rem return returning
   an exponent (**) and or || (DBD ERROR: OCIStmtExecute) at getinv.p
line 75.
func_name returned '0'



Can anyone tell me what code I have set up incorrectly here?  Please
reply directly as I just subscribed to the list.

Thanks

Carlin Anderson
[EMAIL PROTECTED]
[EMAIL PROTECTED]
[EMAIL PROTECTED]


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]