niXforums Forum Index
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   PreferencesPreferences   Log in to check your private messagesLog in to check your private messages   Log inLog in 
·  nixdoc.net ·  man pages ·  Linux HOWTOs ·  FreeBSD Tips ·  Forums
navigation Forum index » Programming » Perl » modules
manipulate csv module
Post new topic   Reply to topic Page 1 of 1 [4 Posts] View previous topic :: View next topic
Author Message
lancerset@gmail.com
*nix forums beginner


Joined: 21 Mar 2006
Posts: 29

PostPosted: Thu Jun 22, 2006 4:24 pm    Post subject: Re: manipulate csv module Reply with quote

Thanks for the response. I found Tie::Handle::CSV which seems to be ok.
I am trying to
iterate over the Title column so i can perform an action on each piece
of data.
I am trying a while loop but not working out too well. Any
suggestions.?
Thanks,

$csv_fh = Tie::Handle::CSV->new( 'file01.csv', openmode => '+<' );

print +( scalar <$csv_fh> )->{'Title'}, "\n";

This is not working:
while ($csv_fh->{'Title'}){
print "bla bla\n";
}




Bob Lanteigne wrote:
Quote:
onlineviewer wrote:
Hello All,

I have a .csv file which has 3 columns of data. Is there a
module that i can use that will allow me to manipulate this file.
Like remove some data from 1 column and add it to another, add
and remove columns etc...

Thanks,

Googling "perl text csv" returns a link to:

Module: Text::CSV

Description:
Text::CSV provides facilities for the composition and decomposition
of
comma-separated values. An instance of the Text::CSV class can
combine
fields into a CSV string and parse a CSV string into fields.
snip

Might be a good place to start.
Back to top
harryfmudd [AT] comcast [
*nix forums addict


Joined: 15 Oct 2005
Posts: 82

PostPosted: Thu Jun 22, 2006 3:32 pm    Post subject: Re: manipulate csv module Reply with quote

Bob Lanteigne wrote:
Quote:
onlineviewer wrote:

Hello All,

I have a .csv file which has 3 columns of data. Is there a
module that i can use that will allow me to manipulate this file.
Like remove some data from 1 column and add it to another, add
and remove columns etc...

Thanks,


Googling "perl text csv" returns a link to:

Module: Text::CSV

Description:
Text::CSV provides facilities for the composition and decomposition
of
comma-separated values. An instance of the Text::CSV class can
combine
fields into a CSV string and parse a CSV string into fields.
snip

Might be a good place to start.


Searching http://search.cpan.org/ for CSV also works.

Tom Wyant
Back to top
Bob Lanteigne
*nix forums beginner


Joined: 22 Jun 2006
Posts: 1

PostPosted: Thu Jun 22, 2006 11:15 am    Post subject: Re: manipulate csv module Reply with quote

onlineviewer wrote:
Quote:
Hello All,

I have a .csv file which has 3 columns of data. Is there a
module that i can use that will allow me to manipulate this file.
Like remove some data from 1 column and add it to another, add
and remove columns etc...

Thanks,

Googling "perl text csv" returns a link to:

Module: Text::CSV

Description:
Text::CSV provides facilities for the composition and decomposition
of
comma-separated values. An instance of the Text::CSV class can
combine
fields into a CSV string and parse a CSV string into fields.
<snip>

Might be a good place to start.
Back to top
lancerset@gmail.com
*nix forums beginner


Joined: 21 Mar 2006
Posts: 29

PostPosted: Thu Jun 22, 2006 2:53 am    Post subject: manipulate csv module Reply with quote

Hello All,

I have a .csv file which has 3 columns of data. Is there a
module that i can use that will allow me to manipulate this file.
Like remove some data from 1 column and add it to another, add
and remove columns etc...

Thanks,
Back to top
Google

Back to top
Display posts from previous:   
Post new topic   Reply to topic Page 1 of 1 [4 Posts] View previous topic :: View next topic
The time now is Fri Jan 09, 2009 11:00 pm | All times are GMT
navigation Forum index » Programming » Perl » modules
Jump to:  

Similar Topics
Topic Author Forum Replies Last Post
No new posts strange error when importing a module Robin Becker python 1 Thu Jul 20, 2006 4:04 pm
No new posts subprocess module Bulkan-Savun Evcimen python 0 Thu Jul 20, 2006 1:59 pm
No new posts Load Module Kaushal Shriyan Apache 1 Tue Jul 18, 2006 12:52 pm
No new posts RFC: my iterthreader module Justin Azoff python 0 Tue Jul 18, 2006 3:15 am
No new posts using logger module David Bear python 2 Mon Jul 17, 2006 4:36 pm

Debt Consolidation | Credit Counseling | Free Animated Greetings | Free Ringtones | Problem Mortgage
Copyright © 2004-2005 DeniX Solutions SRL
 
Other DeniX Solutions sites: Unix/Linux blog |  electronics forum |  medicine forum |  science forum | 
Privacy Policy


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.2325s ][ Queries: 20 (0.1385s) ][ GZIP on - Debug on ]