Index: main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/reports/tests/test_level_report.py
===================================================================
--- main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/reports/tests/test_level_report.py	(revision 18316)
+++ main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/reports/tests/test_level_report.py	(revision 18317)
@@ -41,5 +41,5 @@
         result = lr._get_students('fac1', 'dep1', 'CERT1', 2010, 100)
         self.assertEqual(result,
-            [(u'1234', u'Bob Tester', 91, 91, '5.00',
+            [(u'1234', u'TESTER, Bob', 91, 91, '5.00',
                'Nil', 'Nil', 91, 91, 77,'5.00', '1s_st_s')])
         return
Index: main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/reports/tests/test_raw_score_report.py
===================================================================
--- main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/reports/tests/test_raw_score_report.py	(revision 18316)
+++ main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/reports/tests/test_raw_score_report.py	(revision 18317)
@@ -52,9 +52,9 @@
         result = rsr._get_students('fac1', 'dep1', 'CERT1', 2010, 100, course_codes)
         self.assertEqual(result,
-            [(u'1234', u'Bob Tester', {'Course1': (70, 'A')})])
+            [(u'1234', u'TESTER, Bob', {'Course1': (70, 'A')})])
         self.student['studycourse']['100']['Course1'].ca = None
         result = rsr._get_students('fac1', 'dep1', 'CERT1', 2010, 100, course_codes)
         self.assertEqual(result,
-            [(u'1234', u'Bob Tester', {'Course1': ('Nil', '')})])
+            [(u'1234', u'TESTER, Bob', {'Course1': ('Nil', '')})])
         return
 
@@ -152,5 +152,5 @@
         result = rsr._get_students('fac1', 'dep1', 'CERT1', 2010, 100, course_codes)
         self.assertEqual(result,
-            [(u'1234', u'Bob Tester', {'Course1': (70, 'A')})])
+            [(u'1234', u'TESTER, Bob', {'Course1': (70, 'A')})])
         self.student['studycourse']['100']['Course1'].ca = None
         result = rsr._get_students('fac1', 'dep1', 'CERT1', 2010, 100, course_codes)
Index: main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/reports/tests/test_session_results_presentation.py
===================================================================
--- main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/reports/tests/test_session_results_presentation.py	(revision 18316)
+++ main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/reports/tests/test_session_results_presentation.py	(revision 18317)
@@ -35,10 +35,10 @@
         result = sr._get_students('fac1', 'dep1', 'CERT1', 2010, 100)
         self.assertEqual(result,
-            [[(u'D1000000', u'1234', u'Bob Tester')], [], [], [], [], [], []])
+            [[(u'D1000000', u'1234', u'TESTER, Bob')], [], [], [], [], [], []])
         self.student['studycourse']['100']['Course1'].score = 60
         self.student['studycourse']['100']['Course1'].ca = 10
         result = sr._get_students('fac1', 'dep1', 'CERT1', 2010, 100)
         self.assertEqual(result,
-            [[], [], [], [], [], [(u'D1000000', u'1234', u'Bob Tester')], []])
+            [[], [], [], [], [], [(u'D1000000', u'1234', u'TESTER, Bob')], []])
         return
 
@@ -96,5 +96,5 @@
         result = sr._get_students('fac1', 'dep1', 'CERT1', 2010, 100)
         self.assertEqual(result,
-            [[], [], [], [], [], [(u'D1000000', u'1234', u'Bob Tester')], []])
+            [[], [], [], [], [], [(u'D1000000', u'1234', u'TESTER, Bob')], []])
         return
 
Index: main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/tests/test_browser.py
===================================================================
--- main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/tests/test_browser.py	(revision 18316)
+++ main/kofacustom.unidel/trunk/src/kofacustom/unidel/students/tests/test_browser.py	(revision 18317)
@@ -225,5 +225,5 @@
         upload_ctrl.add_file(upload_file, 'text/csv', 'myscores.csv')
         self.browser.getControl("Update editable scores from").click()
-        self.assertTrue('Anna Tester have not be updated' in self.browser.contents)
+        self.assertTrue('TESTER, Anna have not be updated' in self.browser.contents)
         # values have not been changed
         self.assertEqual(
@@ -288,5 +288,5 @@
         self.browser.open(self.edit_scores_url)
         self.assertFalse('No student found' in self.browser.contents)
-        self.assertTrue('Anna Tester' in self.browser.contents)
+        self.assertTrue('TESTER, Anna' in self.browser.contents)
 
     def test_lecturers_can_download_attendance_sheet(self):
Index: main/kofacustom.unidel/trunk/src/kofacustom/unidel/utils/utils.py
===================================================================
--- main/kofacustom.unidel/trunk/src/kofacustom/unidel/utils/utils.py	(revision 18316)
+++ main/kofacustom.unidel/trunk/src/kofacustom/unidel/utils/utils.py	(revision 18317)
@@ -18,4 +18,5 @@
 """Customize general helper utilities for Kofa.
 """
+import string
 from copy import deepcopy
 from kofacustom.nigeria.utils.utils import NigeriaKofaUtils
@@ -151,2 +152,38 @@
         'alero': 'Owa-Alero Campus Hostel',
         }
+
+    def fullname(self, firstname, lastname, middlename=None):
+        """Construct fullname.
+        """
+        try:
+            lastname = lastname.upper()
+        except AttributeError:
+            pass
+        # We remove single initial
+        if firstname and len(firstname) == 1:
+            firstname = ''
+        if middlename and len(middlename) == 1:
+            middlename = ''
+        if lastname and len(lastname) == 1:
+            lastname = ''
+        # We construct givennames
+        givennames = ''
+        if middlename and firstname:
+            givennames = '%s %s' % (firstname, middlename)
+        elif firstname:
+            givennames = firstname
+        elif middlename:
+            givennames = middlename
+        givennames = string.capwords(
+            givennames.replace('-', ' - ')).replace(' - ', '-')
+        # We construct fullname
+        fullname = ''
+        if lastname and givennames:
+            fullname = '%s, %s' % (lastname, givennames)
+        elif lastname:
+            fullname = lastname
+        elif givennames:
+            fullname = givennames
+        if '<' in fullname:
+            return 'XXX'
+        return fullname
