Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
control_sql_-_find_off-of-balance_sheet_issues [2019/01/27 11:28]
127.0.0.1 external edit
control_sql_-_find_off-of-balance_sheet_issues [2019/04/23 09:44]
mjohnson [SQL]
Line 17: Line 17:
 ===== Risk of Data Corruption if Run Improperly ===== ===== Risk of Data Corruption if Run Improperly =====
  
- +The selection of this data for examination poses no risks. However, some of the queries following it do alter data irrevocably and should only be used by a skilled technician.
- +
-The selection of this data for examination poses no risks.  However, some of the queries following it do alter data irrevocably and should only be used by a skilled technician. +
  
  
Line 56: Line 53:
     WHERE EntryDateTime >= @StartDate     WHERE EntryDateTime >= @StartDate
     GROUP BY Coalesce(DivisionID, 10), COALESCE (TransactionID, 0), OffBalanceSheet     GROUP BY Coalesce(DivisionID, 10), COALESCE (TransactionID, 0), OffBalanceSheet
-    HAVING    (SUM(Amount)  0)+    HAVING    (SUM(Amount)>0)
 ) AS OOBGL ) AS OOBGL