Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: Clarification on Class::DBI wackiness

by cees (Curate)
on Aug 03, 2005 at 16:57 UTC ( [id://480564]=note: print w/replies, xml ) Need Help??


in reply to Clarification on Class::DBI wackiness

Try and use set_up_table instead of table and columns to configure your CDBI class to see if that makes a difference.

__PACKAGE__->set_up_table('users');

set_up_table will read all the table information (like column names and primary keys and more) directly from the DB and setup your CDBI class for you.

Replies are listed 'Best First'.
Re^2: Clarification on Class::DBI wackiness
by spork (Monk) on Aug 03, 2005 at 17:37 UTC
    Good tip. However set_up_table() returned all of the column names (original post represented a subset of the table columns) but still presented the "statement handle" error message when running search().

    I'm stumped as to why retrieve_all() is successful while search is not coming from the same base class.

      Are you sure it is not something else in your code that is causing this. The code you provide above looks like it should work fine. But your error message mentions the error occurs on line 35 of your test file. This tells me you have a bunch of other stuff in your test file. Strip your code down to bare minimum and test it again.

      Also, test your code out using SQLite instead of Sybase. This may give you a hint as to what is going wrong as well. If the same error happens again, then we know it isn't the Sybase module causing the problem, and most likely it is with your code.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://480564]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (6)
As of 2024-03-28 23:38 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found