Index: main/waeup.kofa/trunk/src/waeup/kofa/students/batching.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/batching.py	(revision 9466)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/batching.py	(revision 9467)
@@ -679,5 +679,5 @@
         # by Excel or Calc
         p_id = p_id.strip('#')
-        if not p_id.startswith('p'):
+        if len(p_id.split('-')) != 3 and not p_id.startswith('p'):
             # For data migration from old SRP only
             p_id = 'p' + p_id[7:] + '0'
@@ -699,5 +699,5 @@
         parent = self.getParent(row, site)
         p_id = row['p_id'].strip('#')
-        if not p_id.startswith('p'):
+        if len(p_id.split('-')) != 3 and not p_id.startswith('p'):
             # For data migration from old SRP
             obj.p_id = 'p' + p_id[7:] + '0'
@@ -736,5 +736,11 @@
                 errs.append(('p_id','invalid length'))
                 return errs, inv_errs, conv_dict
+        elif len(p_id.split('-')) == 3:
+            # The SRP used either pins as keys ...
+            if len(p_id.split('-')[2]) != 10:
+                errs.append(('p_id','invalid pin'))
+                return errs, inv_errs, conv_dict
         else:
+            # ... or order_ids.
             if not len(p_id) == 19:
                 errs.append(('p_id','invalid length'))
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py	(revision 9466)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py	(revision 9467)
@@ -27,5 +27,5 @@
 from zope.catalog.interfaces import ICatalog
 from zope.component import queryUtility, getUtility, createObject
-from zope.schema.interfaces import ConstraintNotSatisfied
+from zope.schema.interfaces import ConstraintNotSatisfied, RequiredMissing
 from zope.formlib.textwidgets import BytesDisplayWidget
 from hurry.workflow.interfaces import IWorkflowInfo, IWorkflowState
@@ -2108,4 +2108,6 @@
         except KeyError:
             self.flash(_('This level exists.'))
+        except RequiredMissing:
+            self.flash(_('Your data are incomplete'))
         self.redirect(self.url(self.context))
         return
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/tests/sample_payment_data.csv
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/tests/sample_payment_data.csv	(revision 9466)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/tests/sample_payment_data.csv	(revision 9467)
@@ -3,2 +3,3 @@
 100001,unpaid,schoolfee,3816951290712593757,,2010,0,BTECHBDT,19500.1,0942,Z0,2010-11-25 20:16:33.757 WAT,online,0
 ,paid,schoolfee,p1266236341955,3,2009,19500,BTECHBDT,19500,0615,00,2010/02/15 13:19:01,online,1
+,paid,schoolfee,ABC-11-1234567890,3,2011,19500,BTECHBDT,19500.6,,SC,2010/02/15 13:19:01,sc,1
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_batching.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_batching.py	(revision 9466)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_batching.py	(revision 9467)
@@ -909,4 +909,5 @@
         payment1.p_id = 'nonsense'
         # payment1.p_id will be replaced if p_id doesn't start with 'p'
+        # and is not an old PIN
         self.processor.addEntry(
             payment2, dict(student_id=self.student.student_id, p_id='XXXXXX456'),
@@ -923,4 +924,7 @@
         self.assertEqual(len(errs),0)
         errs, inv_errs, conv_dict = self.processor.checkConversion(
+            dict(p_id='ABC-11-1234567890'))
+        self.assertEqual(len(errs),0)
+        errs, inv_errs, conv_dict = self.processor.checkConversion(
             dict(p_id='nonsense'))
         self.assertEqual(len(errs),1)
@@ -935,4 +939,5 @@
             self.csv_file, PAYMENT_HEADER_FIELDS,'create')
         self.assertEqual(num_warns,0)
+
         payment = self.processor.getEntry(dict(reg_number='1',
             p_id='p2907979737440'), self.app)
@@ -942,4 +947,5 @@
         self.assertEqual(cdate, "2010-11-26 18:59:33")
         self.assertEqual(str(payment.creation_date.tzinfo),'UTC')
+
         payment = self.processor.getEntry(dict(matric_number='100001',
             p_id='p2907125937570'), self.app)
@@ -953,4 +959,9 @@
         self.assertEqual(cdate, "2010-11-25 21:16:33")
         self.assertEqual(str(payment.creation_date.tzinfo),'UTC')
+
+        payment = self.processor.getEntry(dict(reg_number='3',
+            p_id='ABC-11-1234567890'), self.app)
+        self.assertEqual(payment.amount_auth, 19500.6)
+
         shutil.rmtree(os.path.dirname(fin_file))
         logcontent = open(self.logfile).read()
@@ -961,4 +972,11 @@
             'p_category=schoolfee, amount_auth=19500.0, p_current=True, '
             'p_id=p1266236341955, r_code=00, r_amount_approved=19500.0, '
+            'p_state=paid'
+            in logcontent)
+        self.assertTrue(
+            'INFO - system - K1000001 - Payment ticket updated: '
+            'p_item=BTECHBDT, creation_date=2010-02-15 13:19:01+00:00, '
+            'p_category=schoolfee, amount_auth=19500.6, p_current=True, '
+            'p_id=ABC-11-1234567890, r_code=SC, r_amount_approved=19500.0, '
             'p_state=paid'
             in logcontent)
