Advertisement

07.10.2005 at 03:11PM PDT, ID: 21486510
[x]
Attachment Details

Perl Script - Text::CSV::Simple.pm - @INC Problem

Asked by WizeOwl in Perl Programming Language

Tags: locate

I've installed Active State Perl v5.8.7 (b.813) on my Windows XP machine.  I then downloaded five modules, unzipped them, and copied the pm files to appropriate directories under C:/Perl/lib/.. creating folders as needed.  (is there an 'install' procedure I must run to install modules?)

http://search.cpan.org/~alancitt/Text-CSV-0.01/CSV.pm                                                       ->  ../lib/Text/CSV
http://search.cpan.org/~jwied/Text-CSV_XS-0.23/CSV_XS.pm                                              ->  ../lib/Text/CSV
http://search.cpan.org/~tmtm/Text-CSV-Simple-0.20/lib/Text/CSV/Simple.pm                        ->  ../lib/Text/CSV
http://search.cpan.org/~miyagawa/Class-Trigger-0.09/lib/Class/Trigger.pm                            ->  ../lib/Class/
http://search.cpan.org/~mschwern/Class-Data-Inheritable-0.02/lib/Class/Data/Inheritable.pm   ->  ../lib/Class/Data/

I'm using the wrapper code:

#!/perl/perl -w
use strict;
use Text::CSV::Simple;
my ($parser, @data);
my $datafile = 'datafile.csv';
my $csvout = 'csvout.csv';
push (@INC,'c:/Perl/lib/Text/CSV');
# Only want certain fields?
$parser = Text::CSV::Simple->new;
$parser->want_fields(1, 2, 4, 8);
@data = $parser->read_file($datafile);
open (CSV, "> $csvout") or die "can't open $csvout $!";
print CSV @data;
close CSV;

I am getting the following error:

C:\>perl test.pl
Can't locate Text/CSV_XS.pm in @INC (@INC contains: C:/Perl/lib C:/Perl/site/lib .)
at C:/Perl/lib/Text/CSV/Simple.pm line 18.
BEGIN failed--compilation aborted at C:/Perl/lib/Text/CSV/Simple.pm line 18.
Compilation failed in require at test.pl line 4.
BEGIN failed--compilation aborted at test.pl line 4.
Start Free Trial
 
 
[+][-]07.10.2005 at 03:19PM PDT, ID: 14408384

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zone: Perl Programming Language
Tags: locate
Sign Up Now!
Solution Provided By: ozo
Participating Experts: 5
Solution Grade: A
 
 
[+][-]07.10.2005 at 03:25PM PDT, ID: 14408402

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 7-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]07.10.2005 at 04:52PM PDT, ID: 14408579

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.10.2005 at 05:14PM PDT, ID: 14408630

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.10.2005 at 05:57PM PDT, ID: 14408784

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.10.2005 at 06:24PM PDT, ID: 14408907

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.10.2005 at 06:32PM PDT, ID: 14408928

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.10.2005 at 10:13PM PDT, ID: 14409484

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.11.2005 at 12:01AM PDT, ID: 14409764

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 7-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]07.11.2005 at 12:27AM PDT, ID: 14409864

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.11.2005 at 07:35AM PDT, ID: 14412647

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]09.22.2005 at 04:39AM PDT, ID: 14935740

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]09.22.2005 at 05:18AM PDT, ID: 14935964

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]09.22.2005 at 06:36AM PDT, ID: 14936497

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]09.22.2005 at 06:39AM PDT, ID: 14936522

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]09.22.2005 at 06:54AM PDT, ID: 14936661

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32