Index: trunk/pstamp/scripts/pstampparse.pl
===================================================================
--- trunk/pstamp/scripts/pstampparse.pl	(revision 32271)
+++ trunk/pstamp/scripts/pstampparse.pl	(revision 32940)
@@ -254,4 +254,6 @@
     # If we encounter an error for a particular row add a job with the proper fault code.
 
+    my $stage = $row->{IMG_TYPE};
+
     my $rownum   = $row->{ROWNUM};
     if (!validID($rownum)) {
@@ -275,6 +277,6 @@
     }
     if ($job_type eq 'get_image') {
-        unless ($req_type eq 'byid' or $req_type eq 'byexp') {
-            print STDERR "REQ_TYPE must be 'byid' or 'byexp' for JOB_TYPE 'get_image'\n";
+        unless ($req_type eq 'byid' or $req_type eq 'byexp' or ($req_type eq 'byskycell' and $stage eq 'stack')) {
+            print STDERR "REQ_TYPE must be 'byid' or 'byexp' or byskcyell for stacks for JOB_TYPE 'get_image'\n";
             insertFakeJobForRow($row, 1, $PSTAMP_INVALID_REQUEST);
             return 0;
@@ -337,5 +339,4 @@
     }
 
-    my $stage = $row->{IMG_TYPE};
     if (!check_image_type($stage)) {
         print STDERR "invalid IMG_TYPE for row $rownum\n";
@@ -463,4 +464,8 @@
     my $numRows = scalar @$rowList;
 
+    if (($req_type eq 'byskycell') or ($req_type eq 'bycoord')) {
+        # avoid error from print below if $id isn't needed
+        $id = "" if !$id;
+    }
     print "Collected $numRows rows beginning with row $rownum. $req_type $stage $id $tess_id $component\n";
     
