Index: trunk/FACT++/src/Fits.cc
===================================================================
--- trunk/FACT++/src/Fits.cc	(revision 12847)
+++ trunk/FACT++/src/Fits.cc	(revision 12848)
@@ -23,4 +23,6 @@
 #include <cstdio> // for file rename
 #include <cerrno>
+
+#include <boost/algorithm/string/predicate.hpp>
 
 using namespace std;
@@ -63,31 +65,52 @@
     fDataPointer = dataPointer;
 
-    //we will copy this information here. It duplicates the data, which is not great, but it is the easiest way of doing it right now
-    if ((desc.size() == dataFormat.size()+1) || //regular service
-        (desc.size() == dataFormat.size()+2))//service with ending string. skipped in fits
-    {//services have one (or two) more description than columns. skip the first entry while copying as it describes the table itself.
+    //we will copy this information here. It duplicates the data, which is not great,
+    // but it is the easiest way of doing it right now
+    if (
+        (desc.size() == dataFormat.size()+1) || // regular service
+        (desc.size() == dataFormat.size()+2)    // service with ending string. skipped in fits
+       )
+    {
+        //services have one (or two) more description than columns. skip the first entry while copying as it describes the table itself.
+
         fDataColDesc.clear();
+
         fTableDesc = desc[0].comment;
         if (fTableDesc.size() > 68)
         {
-            out->Warn("Table description \"" + fTableDesc + "\" too long. truncating it (68 char max.)");
+            out->Warn("Table description '" + fTableDesc + "' exceeds 68 chars... truncated.");
             fTableDesc = fTableDesc.substr(0,68);
         }
-        for (unsigned int i=0;i<dataFormat.size(); i++)
+
+        for (unsigned int i=0; i<dataFormat.size(); i++)
         {
             string name = desc[i+1].name;
             if (name.length() > 68)
             {
-                out->Warn("Column name " + name + "too long. truncating it (68 char max.)");
+                out->Warn("Column name '" + name + "' exceeds 68 chars... truncated.");
                 name = name.substr(0, 68);
             }
+
             string comment = desc[i+1].comment;
-            if ((comment.length() + name.length()) > 71)
+            if (comment.length() + name.length() > 71)
             {
-                out->Warn("Column " + name + " added to \"" + comment + "\" too long. truncating to fit 68 chars.");
+                out->Warn("Column '" + name + " / " + comment + "' exceeds 68 chars... truncated.");
                 comment = comment.substr(0,68);
             }
+
             string unit = desc[i+1].unit;
-            if (unit.length() > 68)  unit = comment.substr(0,68);
+            if (unit.length() > 68)
+            {
+                out->Warn("Unit '" + name + "' exceeds 68 chars... truncated.");
+                unit = comment.substr(0,68);
+            }
+
+            const size_t p = fDataFormats[i].find_last_of('B');
+            if ((boost::iequals(unit, "text") || boost::iequals(unit, "string")) && p!=string::npos)
+            {
+                out->Info("Column '" + name + "' detected to be an ascii string (FITS format 'A').");
+                fDataFormats[i].replace(p, 1, "A");
+            }
+
             fDataColDesc.push_back(Description(name, comment, unit));
         }
