Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: Get output AnyData script without header or data_row

by jZed (Prior)
on Dec 19, 2007 at 18:30 UTC ( #657946=note: print w/ replies, xml ) Need Help??


in reply to Get output AnyData script without header or data_row

DBD::AnyData can handle column names two ways: by default it looks for them as the first record in the file and treats that row as a header, not as a data row. However, if you specifically set the column names (as you do in the script above), then it will assume that the first row is data, not a header. So to get it to work as you want, just take out the col_names specification in your ad_catalog().


Comment on Re: Get output AnyData script without header or data_row
Re^2: Get output AnyData script without header or data_row
by GertMT (Friar) on Dec 19, 2007 at 18:39 UTC
    Okay, I'm going to 'close' the file but obviously also take advantage of this explanation.

    Thanks, great module.
      I think what you'll want to do is have two ad_catalog() calls - the first to read the existing files with headers should not specify col_names, the second, to write a new file without headers should specify col_names. That way you do it all with the DBD and don't have to do any explicit file opening, writing, or closing.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (9)
As of 2014-08-23 18:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (178 votes), past polls