Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
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
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 drinking their drinks and smoking their pipes about the Monastery: (14)
As of 2014-09-30 12:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (368 votes), past polls