Index: /main/waeup.kofa/trunk/src/waeup/kofa/browser/pages.py
===================================================================
--- /main/waeup.kofa/trunk/src/waeup/kofa/browser/pages.py	(revision 8650)
+++ /main/waeup.kofa/trunk/src/waeup/kofa/browser/pages.py	(revision 8651)
@@ -931,22 +931,26 @@
         return reader.next()
 
-    def getPreviewBody(self):
-        """Get the first 5 rows of attached CSV file.
+    def getPreviewTable(self):
+        """Get transposed table with 3 sample records.
+
+        The first column contains the headers.
         """
-        result = []
+        if not self.reader:
+            return
+        header = self.getPreviewHeader()
         num = 0
-        if not self.reader:
-            return
-        for row in self.reader:
-            if num > 4:
+        data = []
+        for line in self.reader:
+            if num > 2:
                 break
             num += 1
-            row = row.items()
-            # Sort fields in headerfield order
-            row = sorted(row,
-                         key=lambda k: self.reader.fieldnames.index(k[0]))
-            row = [x[1] for x in row]
-            result.append(row)
-        result.append(len(result[0]) * ['...'])
+            data.append(line)
+        result = []
+        for name in header:
+            result_line = []
+            result_line.append(name)
+            for d in data:
+                result_line.append(d[name])
+            result.append(result_line)
         return result
 
@@ -1056,20 +1060,26 @@
         return reader.next()
 
-    def getPreviewBody(self):
-        """Get the first 5 rows of attached CSV file.
+    def getPreviewTable(self):
+        """Get transposed table with 1 sample record.
+
+        The first column contains the headers.
         """
-        result = []
+        if not self.reader:
+            return
+        header = self.getPreviewHeader()
         num = 0
-        for row in self.reader:
-            if num > 4:
+        data = []
+        for line in self.reader:
+            if num > 0:
                 break
             num += 1
-            row = row.items()
-            # Sort fields in headerfield order
-            row = sorted(row,
-                         key=lambda k: self.reader.fieldnames.index(k[0]))
-            row = [x[1] for x in row]
-            result.append(row)
-        result.append(len(result[0]) * ['...'])
+            data.append(line)
+        result = []
+        for name in header:
+            result_line = []
+            result_line.append(name)
+            for d in data:
+                result_line.append(d[name])
+            result.append(result_line)
         return result
 
@@ -1106,4 +1116,5 @@
 
     def update(self, headerfield=None, back2=None, cancel=None, proceed=None):
+        datatable.need()
         session = ISession(self.request)['waeup.kofa']
         self.filename = session.get('import_filename', None)
Index: /main/waeup.kofa/trunk/src/waeup/kofa/browser/templates/datacenterimport2page.pt
===================================================================
--- /main/waeup.kofa/trunk/src/waeup/kofa/browser/templates/datacenterimport2page.pt	(revision 8650)
+++ /main/waeup.kofa/trunk/src/waeup/kofa/browser/templates/datacenterimport2page.pt	(revision 8651)
@@ -10,17 +10,15 @@
   </p>
   <div>
-    <table
-       tal:define="body view/getPreviewBody;
-                    headers view/getPreviewHeader;
-                    fieldnum python: len(headers)">
+    <table tal:define="prev_table view/getPreviewTable;">
       <thead>
         <tr>
-          <th tal:repeat="headerfield headers"
-              tal:content="headerfield"> headerfield
-          </th>
+          <th i18n:translate="">Header</th>
+          <th i18n:translate="">Sample Record 1</th>
+          <th i18n:translate="">Sample Record 2</th>
+          <th i18n:translate="">Sample Record 3</th>
         </tr>
       </thead>
       <tbody>
-        <tr tal:repeat="row body">
+        <tr tal:repeat="row prev_table">
           <td tal:repeat="value row"
               tal:content="value"> value
Index: /main/waeup.kofa/trunk/src/waeup/kofa/browser/templates/datacenterimport3page.pt
===================================================================
--- /main/waeup.kofa/trunk/src/waeup/kofa/browser/templates/datacenterimport3page.pt	(revision 8650)
+++ /main/waeup.kofa/trunk/src/waeup/kofa/browser/templates/datacenterimport3page.pt	(revision 8651)
@@ -29,38 +29,31 @@
 
   <div>
-    <table class="condensed-table"
-     tal:define="body view/getPreviewBody;
-           headers view/headerfields;
-           fieldnum python: len(headers)">
+
+
+    <table tal:define="prev_table view/getPreviewTable;
+                       headers view/headerfields;">
       <thead>
         <tr>
-          <th tal:repeat="headerfield headers"
-              tal:content="headerfield">
-            headerfield
-          </th>
+          <th i18n:translate="">Header</th>
+          <th i18n:translate="">change to</th>
+          <th i18n:translate="">Sample Record</th>
         </tr>
-        <tr>
-          <th tal:repeat="headerfield headers">
-            <i i18n:translate="">change to:</i>
-          </th>
-        </tr>
-        <tr>
-          <th tal:repeat="headerfield headers">
-            <select name="headerfield">
+      </thead>
+      <tbody>
+        <tr tal:repeat="row prev_table">
+          <td tal:content="python:row[0]"> value
+          </td>
+          <td>
+            <select class="span4" name="python:row[0]">
               <option tal:repeat="opt view/getPossibleHeaders"
                 tal:attributes="value opt/value;
-                  selected python: opt['value']==headerfield and 'selected' or '';"
+                  selected python: opt['value']==row[0] and 'selected' or '';"
                 tal:content="opt/title">
                 new_header_name
               </option>
             </select>
-          </th>
-        </tr>
-      </thead>
-      <tbody>
-        <tr tal:repeat="row body">
-          <td tal:repeat="value row"
-              tal:content="value">
-            value
+          </td>
+          <td tal:repeat="value python:row[1:]"
+              tal:content="value"> value
           </td>
         </tr>
