]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/Python/Table/TableReport.py
There is a limitation on WINDOWS OS for the length of entire file path can’t be large...
[mirror_edk2.git] / BaseTools / Source / Python / Table / TableReport.py
index 042c1b7e9e792e61f7dbd34c40b30a1a814e04ca..4065a43c5b55a4df81a61341bafcdc8d9a8fc90c 100644 (file)
@@ -1,8 +1,8 @@
 ## @file\r
 # This file is used to create/update/query/erase table for ECC reports\r
 #\r
-# Copyright (c) 2008, Intel Corporation\r
-# All rights reserved. This program and the accompanying materials\r
+# Copyright (c) 2008 - 2014, Intel Corporation. All rights reserved.<BR>\r
+# This program and the accompanying materials\r
 # are licensed and made available under the terms and conditions of the BSD License\r
 # which accompanies this distribution.  The full text of the license may be found at\r
 # http://opensource.org/licenses/bsd-license.php\r
 # Import Modules\r
 #\r
 import Common.EdkLogger as EdkLogger\r
-import os, time\r
+import Common.LongFilePathOs as os, time\r
 from Table import Table\r
 from Common.String import ConvertToSqlString2\r
 import EccToolError as EccToolError\r
 import EccGlobalData as EccGlobalData\r
+from Common.LongFilePathSupport import OpenLongFilePath as open\r
 \r
 ## TableReport\r
 #\r
@@ -105,7 +106,7 @@ class TableReport(Table):
                 IsCorrected = Record[5]\r
                 SqlCommand = ''\r
                 if BelongsToTable == 'File':\r
-                    SqlCommand = """select 0, FullPath from %s where ID = %s\r
+                    SqlCommand = """select 1, FullPath from %s where ID = %s\r
                              """ % (BelongsToTable, BelongsToItem)\r
                 else:\r
                     SqlCommand = """select A.StartLine, B.FullPath from %s as A, File as B\r
@@ -114,7 +115,8 @@ class TableReport(Table):
                 NewRecord = self.Exec(SqlCommand)\r
                 if NewRecord != []:\r
                     File.write("""%s,%s,"%s",%s,%s,"%s"\n""" % (Index, ErrorID, EccToolError.gEccErrorMessage[ErrorID], NewRecord[0][1], NewRecord[0][0], OtherMsg))\r
-            \r
+                    EdkLogger.quiet("%s(%s): [%s]%s %s" % (NewRecord[0][1], NewRecord[0][0], ErrorID, EccToolError.gEccErrorMessage[ErrorID], OtherMsg))\r
+                    \r
             File.close()\r
         except IOError:\r
             NewFilename = 'Report_' + time.strftime("%Y%m%d_%H%M%S.csv", time.localtime())\r