Index: trunk/ippScripts/scripts/phase0_imfile.pl
===================================================================
--- trunk/ippScripts/scripts/phase0_imfile.pl	(revision 9251)
+++ trunk/ippScripts/scripts/phase0_imfile.pl	(revision 9267)
@@ -97,26 +97,26 @@
 # Push the results into the database
 unless ($no_update) {
-    my $command = $p0tool . " " . P0TOOL_MODE() . " " . P0TOOL_EXPTAG() . " " . $exp_tag . " " .
-        P0TOOL_CLASSID() . " " . $class_id; # Command to run p0tool
-    
+    my @command;
+    push @command, $p0tool, P0TOOL_MODE(), P0TOOL_EXPTAG(), $exp_tag, P0TOOL_CLASSID(), $class_id; # Command to run p0tool
+
     foreach my $constant (keys %{CONSTANTS()}) {
-        $command .= " " . CONSTANTS->{$constant} . " " . ($stats->data($constant))->{value};
+	push @command, CONSTANTS->{$constant}, ($stats->data($constant))->{value};
     }
     foreach my $variable (keys %{VARIABLES()}) {
         # Just use the mean value
-        $command .= " " . VARIABLES->{$variable} . " " . ($stats->data($variable))->{mean};
+	push @command, VARIABLES->{$variable}, ($stats->data($variable))->{mean};
     }
-
-    $command .= " " . P0TOOL_BG_MEAN() . " " . $stats->bg_mean();
+    
+    push @command, P0TOOL_BG_MEAN(), $stats->bg_mean(), P0TOOL_BG_STDEV();
     if (defined($stats->bg_stdev())) {
-	$command .= " " . P0TOOL_BG_STDEV() . " " . $stats->bg_stdev();
+	push @command, $stats->bg_stdev();
     } else {
 	# Will not be defined if there is only a single imfile
-	$command .= " " . P0TOOL_BG_STDEV() . " 0";
+	push @command, 0;
     }
-    $command .= " " . P0TOOL_BG_MEAN_STDEV() . " " . $stats->bg_mean_stdev();
+    push @command,  P0TOOL_BG_MEAN_STDEV(), $stats->bg_mean_stdev();
  
     my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) =
-        run(command => $command, verbose => 1);
+        run(command => \@command, verbose => 1);
     die "Unable to perform p0tool -updateimfile: $error_code\n" if not $success;
 }
