Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

DBIx::Class and SQL Server: Can't call ping() with active statement handles ?

by ndixon (Initiate)
on Aug 22, 2008 at 16:25 UTC ( #706222=perlquestion: print w/replies, xml ) Need Help??

ndixon has asked for the wisdom of the Perl Monks concerning the following question:

I'm tearing my hair out on this one.

I'm trying to build a simple Catalyst CRUD application using DBIx::Class 0.08010 and DBD::Sybase connecting to a SQL Server 2005 instance.

I have other (back-end) Perl applications which can select/insert/update/delete using plain old DBI without any problem, so I know that DBD::Sybase is set up correctly.

And in my Catalyst app I can perform select queries (list, search) with no problems either.

But when I try to insert a new record via DBIx::Class::ResultSet::create, I get an error from DBD::Sybase::db like this:

DBI Exception: DBD::Sybase::db ping failed: Can't call ping() with active statement handles at /usr/local/lib/perl5/site_perl/5.8.8/DBIx/Class/Schema.pm line 954

Has anyone else encountered this?

As far as I can tell, this indicates statement handles left unfinished, but since DBIx::* is doing all the work, I can't tell where the problem is.

Strange thing is, the inserts are getting through to the db - the error seems to come afterwards when DBIx::Class tries to get the last_insert_id.

If anyone else has managed to use DBIx::Class to update a SQL Server 2005 database without this error, I'd appreciate knowing how you did it.

  • Comment on DBIx::Class and SQL Server: Can't call ping() with active statement handles ?

Replies are listed 'Best First'.
Re: DBIx::Class and SQL Server: Can't call ping() with active statement handles ?
by mpeppler (Vicar) on Aug 27, 2008 at 13:20 UTC
    I've never used the DBIx:: module(s), so I don't have any real advice - other than checking in DBIx::Class::Schema line 954 to see why this is calling ping() - off hand I don't think that DBD::Sybase does this directly when last_insert_id() is called.

    Michael

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://706222]
Approved by moritz
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (7)
As of 2020-12-02 22:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How often do you use taint mode?





    Results (47 votes). Check out past polls.

    Notices?