]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/Python/Ecc/Check.py
BaseTools: Remove the old python "not-equal"
[mirror_edk2.git] / BaseTools / Source / Python / Ecc / Check.py
index 089d42a6d181989a2d781fa42da22bd591416c26..ea739043e0bca88c58b52d2e5025941e938e15d5 100644 (file)
@@ -787,7 +787,7 @@ class Check(object):
                         continue\r
                     SqlCommand = """select Value3 from Inf where BelongsToFile =\r
                                     (select ID from File where lower(FullPath) = lower('%s'))\r
-                                    and Value2 = '%s'""" % (LibraryIns, 'LIBRARY_CLASS')\r
+                                    and Value2 = '%s'""" % (LibraryIns, DT.PLATFORM_COMPONENT_TYPE_LIBRARY_CLASS)\r
                     RecordSet = EccGlobalData.gDb.TblInf.Exec(SqlCommand)\r
                     IsFound = False\r
                     for Record in RecordSet:\r
@@ -816,8 +816,8 @@ class Check(object):
                     EccGlobalData.gDb.TblReport.Insert(ERROR_META_DATA_FILE_CHECK_LIBRARY_NO_USE, OtherMsg="The Library Class [%s] is not used in any platform" % (Record[1]), BelongsToTable='Inf', BelongsToItem=Record[0])\r
             SqlCommand = """\r
                          select A.ID, A.Value1, A.BelongsToFile, A.StartLine, B.StartLine from Dsc as A left join Dsc as B\r
-                         where A.Model = %s and B.Model = %s and A.Scope1 = B.Scope1 and A.Scope2 = B.Scope2 and A.ID <> B.ID\r
-                         and A.Value1 = B.Value1 and A.Value2 <> B.Value2 and A.BelongsToItem = -1 and B.BelongsToItem = -1 and A.StartLine <> B.StartLine and B.BelongsToFile = A.BelongsToFile""" \\r
+                         where A.Model = %s and B.Model = %s and A.Scope1 = B.Scope1 and A.Scope2 = B.Scope2 and A.ID != B.ID\r
+                         and A.Value1 = B.Value1 and A.Value2 != B.Value2 and A.BelongsToItem = -1 and B.BelongsToItem = -1 and A.StartLine != B.StartLine and B.BelongsToFile = A.BelongsToFile""" \\r
                             % (MODEL_EFI_LIBRARY_CLASS, MODEL_EFI_LIBRARY_CLASS)\r
             RecordSet = EccGlobalData.gDb.TblDsc.Exec(SqlCommand)\r
             for Record in RecordSet:\r
@@ -903,7 +903,7 @@ class Check(object):
                          and A.Value1 = B.Value1\r
                          and A.Value2 = B.Value2\r
                          and A.Scope1 = B.Scope1\r
-                         and A.ID <> B.ID\r
+                         and A.ID != B.ID\r
                          and A.Model = B.Model\r
                          and A.Enabled > -1\r
                          and B.Enabled > -1\r
@@ -1055,7 +1055,7 @@ class Check(object):
             SqlCommand = """\r
                          select A.ID, A.Value3, A.BelongsToFile, B.BelongsToFile from %s as A, %s as B\r
                          where A.Value2 = 'FILE_GUID' and B.Value2 = 'FILE_GUID' and\r
-                         A.Value3 = B.Value3 and A.ID <> B.ID group by A.ID\r
+                         A.Value3 = B.Value3 and A.ID != B.ID group by A.ID\r
                          """ % (Table.Table, Table.Table)\r
             RecordSet = Table.Exec(SqlCommand)\r
             for Record in RecordSet:\r
@@ -1215,7 +1215,7 @@ class Check(object):
         SqlCommand = """\r
                      select A.ID, A.Value1 from %s as A, %s as B\r
                      where A.Model = %s and B.Model = %s\r
-                     and A.Value1 like B.Value1 and A.ID <> B.ID\r
+                     and A.Value1 like B.Value1 and A.ID != B.ID\r
                      and A.Scope1 = B.Scope1\r
                      and A.Enabled > -1\r
                      and B.Enabled > -1\r
@@ -1239,8 +1239,8 @@ class Check(object):
         SqlCommand = """\r
                      select A.ID, A.Value1, A.Value2 from %s as A, %s as B\r
                      where A.Model = %s and B.Model = %s\r
-                     and A.Value2 like B.Value2 and A.ID <> B.ID\r
-                     and A.Scope1 = B.Scope1 and A.Value1 <> B.Value1\r
+                     and A.Value2 like B.Value2 and A.ID != B.ID\r
+                     and A.Scope1 = B.Scope1 and A.Value1 != B.Value1\r
                      group by A.ID\r
                      """ % (Table.Table, Table.Table, Model, Model)\r
         RecordSet = Table.Exec(SqlCommand)\r