I forgot to mention, when I print what is there in the hash after
DBI->connect, I see an extra line(see o/p section) is coming up there.

*Regards*
*Srikantha*
*Mb-9980073640*


On Mon, Nov 2, 2020 at 6:49 PM Srikantha <srikanth...@gmail.com> wrote:

> Basically below connection_hash is causing a core dump. Can you please
> guide me, how I can rewrite this? In the previous email, the Not working db
> handle is using a hash method and which is what dumps core.
>
> code:
> my %connection_hash = (); # keep open connections
>
>    $connection_hash{$dbname} = DBI->connect( $sid, $user, $pass,
{AutoCommit => $autocommit_flag});

> for(keys %connection_hash){
> lib_log::debug_msg("Connection hash of $_ is $connection_hash{$_}\n");
> }
>
> O/p:
>
> 2020/11/02 06:57:25 DEBUG > Connection hash of ORAXX is
> DBI::db=HASH(0x4d463d0)
>
> 2020/11/02 06:57:25 DEBUG > Connection established to ORAXX with
> autocommit = 0
>
> *Regards*
> *Srikantha*
> *Mb-9980073640*
>
>
> On Wed, Oct 28, 2020 at 10:53 PM David Nicol <davidni...@gmail.com> wrote:
>
>>
>> I wonder what the difference between "$sid" and "dbi:$db_driver:$db" is.
>> If nothing, it would look like Oracle::DBD might have some kind of weakness
>> regarding multiple active connections, if the fault happens later instead
>> of right at connect time, like on the second time through, with a different
>> value of $dbname.
>>
>> On Wed, Oct 28, 2020 at 10:06 AM Srikantha <srikanth...@gmail.com> wrote:
>>
>>>
>>> $connection_hash{$dbname} = DBI->connect( $sid, $user, $pass,
>>> {AutoCommit => $autocommit_flag}); -- Not working
>>> my $dbh = DBI->connect("dbi:$db_driver:$db", $user, $pass, { RaiseError
>>> => 1, AutoCommit => 1 }) or die ("failed to login $db_user"); -- Working
>>>
>> --
>> If you are neutral in situations of injustice, you have chosen the side
>> of the oppressor." -- Bshp. Desmond Tutu
>>
>

Reply via email to