Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re^2: adding database values to csv file

by Anonymous Monk
on Sep 27, 2011 at 11:52 UTC ( #928071=note: print w/ replies, xml ) Need Help??


in reply to Re: adding database values to csv file
in thread adding database values to csv file

Hello,
I would like to tie on with my question:
say you need to modify the values bevor printing where could be the best point to do this?
Thank!
VE


Comment on Re^2: adding database values to csv file
Replies are listed 'Best First'.
Re^3: adding database values to csv file
by Tux (Monsignor) on Sep 27, 2011 at 17:38 UTC
    while ($sth->fetch) { $rec{fobar} =~ s{old}{new}; # change in a single co +lumn s/(?:\b|[0-9])USD\b/EUR/g for values %rec; # change all columns $csv->print (*STDOUT, [ @rec{@fld} ]); }

    Enjoy, Have FUN! H.Merijn
      Many thanks!

      VE

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (5)
As of 2015-07-29 01:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (260 votes), past polls