Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling

Re: DBIx::Dump error

by mreece (Friar)
on Mar 26, 2007 at 22:49 UTC ( #606676=note: print w/replies, xml ) Need Help??

in reply to DBIx::Dump error - can't use string as subroutine ref

my $out = DBIx::Dump->new('format' => $format_pass, ...
i think you will find that $format_pass does not eq one of 'excel', 'csv', or 'iQuery'.
if ($format_pass eq "csv") {$filename_pass.=csv;}else {$filename_pass. +=xls;} if (!$filename_pass) {$filename_pass=query.csv;}
you appear to be using bareword strings here, which is very dangerous and bound to bite you at some point. (ie, query.csv is being interpretted as "query"."csv" aka "querycsv" which is possible not what you inteded.)

update: you should consider use strict; to help deal with the bareword issue mentioned above.

i see you have a <select> being printed like so:

<select type="option" name="format"><option>csv<option>xls</select>
according to the docs, you want format => 'excel', not xls.

Replies are listed 'Best First'.
Re^2: DBIx::Dump error
by sparkylu (Monk) on Mar 26, 2007 at 23:14 UTC
    Thank you so much ....

    I forgot to change the $format_pass to excel when xls was selected... That solved the problem ;D

    Can't thank you enough ... it's 4:45 am .. i needed to get back to office by 10am and i was unable to sleep till this got fixed... Thank you ... and Thank You again ;) U Da Man !!!

Re^2: DBIx::Dump error
by sparkylu (Monk) on Mar 26, 2007 at 22:55 UTC
    Thank you ... I will give that a try and let you know the results.

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (3)
As of 2021-01-23 19:22 GMT
Find Nodes?
    Voting Booth?