in reply to Error connecting to Derby DB

You should read DBI and check for errors when connecting:

$dbh = DBI->connect($dsn, "myuser", "mypassword", { RaiseError => 1, A +utoCommit => 0 }) or die "Couldn't connect to '$dsn' as 'myuser'" . $DBI::errstr;

Replies are listed 'Best First'.
Re^2: Error connecting to Derby DB
by jainprithviraj (Initiate) on Apr 09, 2011 at 08:52 UTC

    Hi Corion,

    Thanks for the help. I added (RaiseError => 1, AutoCommit => 0 ), and got the same error.

    Also, one thing that I found while going through the docs is, RaiseError is ON by default. And so the above change made no difference.

    Regards,

    ~Prithvi

      Then why do you ignore the error you get? Resolve

      DBI connect('hostname=localhost;port=1527;url=jdbc:derby:mydb%3Bsecuri +tyMechanism%3D8','myuser',...) failed: I/O Error 001bd00200010015124 +c0006114900080006000c00000005114a03 at tmp.pl line 9

      This is an error raised by the Derby DB or the Derby database driver. We cannot help you there.

        But I am able to connect to Derby DB out of my perl script.It is only through my script that I am seeing this error. And so I thought of requesting a help in Perlmonks.