Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re^3: Class::DBI::AbstractSearch and SpeedyCGI

by zigdon (Deacon)
on Oct 04, 2005 at 11:14 UTC ( #497202=note: print w/replies, xml ) Need Help??


in reply to Re^2: Class::DBI::AbstractSearch and SpeedyCGI
in thread Class::DBI::AbstractSearch and SpeedyCGI

I just tried to add a
warn Dumper $args;
right before the ->execute line... When everything works, it returns what you'd expect ( [ "8880-1" ] ), but when it dies, it didn't output anything? This is just messing me up!

-- zigdon

Replies are listed 'Best First'.
Re^4: Class::DBI::AbstractSearch and SpeedyCGI
by perrin (Chancellor) on Oct 04, 2005 at 18:28 UTC
    I'm guessing that your ID is sometimes undef in your call to search_where(). You might have a bug with the way you are reading this param from CGI, maybe involving a closure.
      All the debugging code I put in never showed a called with an undef for the ID... But even if it was there, it doesn't seem to bomb:
      @r = MyApp::Sets->search_where(ID => undef); print Dumper \@r __OUTPUT__ $VAR1 = [];
      Which is what it should do - return an empty set when the search returns nothing... For now, I've modified Speedy to exit after a single run - this means that I still run my script from the compiled version, but not persistantly. Seems to work around the problem, but of course, not ideal. Any other ideas what I should be looking at? Thanks for all the suggestions so far!

      -- zigdon

        You need to trace it up to the root. You said that $args is not there when the problem occurs, so put in some code in the sub that calls that one and keep going until you see how far up the line the problem is occurring.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (6)
As of 2019-05-25 21:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you enjoy 3D movies?



    Results (152 votes). Check out past polls.

    Notices?
    • (Sep 10, 2018 at 22:53 UTC) Welcome new users!