Dim cmdText As String = "Select EDescription, SUM(EQuantity) AS EQuantity, " & _ "SUM(EAmount) AS EAmount, TDescription,SUM(TQuantity) AS TQuantity, SUM(TAmount) AS TAmount " & _ "From " & _ "(" & _ "SELECT de.Description AS EDescription, de.Quantity AS EQuantity, de.Amount AS EAmount," & _ "0 AS TDescription, 0 AS TQuantity,0 AS TAmount FROM DailyExpenses de " & _ "WHERE de.EDate Between @START and @END " & _ "UNION ALL " & _ "SELECT 0 AS EDescription, 0 AS EQuantity, 0 AS EAmount, " & _ "dt.Description AS TDescription,dt.Quantity AS TQuantity,dt.Amount AS TAmount FROM DailyTransaction dt " & _ "WHERE dt.DTDate Between @START and @END " & _ ") a " & _ "GROUP BY EDescription,TDescription"