in reply to Re: system command with arguments Error
in thread system command with arguments Error

This node falls below the community's threshold of quality. You may see it by logging in.
  • Comment on Re^2: system command with arguments Error

Replies are listed 'Best First'.
Re^3: system command with arguments Error
by davido (Cardinal) on Jan 07, 2013 at 21:27 UTC

    It should also output what the command was, and you should be able to look at that command and see what's wrong with it. We can't perform the debugging steps for you.


    Dave

Re^3: system command with arguments Error
by Anonymous Monk on Jan 07, 2013 at 21:34 UTC

    It should output something more.


    Anyway, a better snippet for debugging:

    use Cwd; my $cmd = "perl Cart.pl $manuf $series $model $url $kb_color_style_nam +e $kb_color_image_url $kb_color_image_id"; print "cmd is $cmd\n"; printf "running at %s\n", getcwd; system($cmd) == 0 or die "cant run!!";

    What does that output?

      Please do output $? and $^E in your error message when system fails.

      system($cmd) == 0 or die "system $cmd failed: $? / $^E"