hi
i have this query:
SELECT DO3Tbl.CodeDip, DO3Tbl.BarcodeD, Sum(DO3Tbl.Qty) AS Qty,
Max(DO3Tbl.Mly) AS Mly, [Qty]-[Mly] AS Tot, ABS(Tot) AS TotAbs
when i run this query in access its work's excellent
but when i run this query in C# code like this:
SQL = SELECT DO3Tbl.CodeDip, DO3Tbl.BarcodeD, Sum(DO3Tbl.Qty) AS Qty,
Max(DO3Tbl.Mly) AS Mly, [Qty]-[Mly] AS Tot, ABS(Tot) AS TotAbs
Cmd = new OleDbCommand(SQL, Conn);
Cmd.ExecuteNonQuery();
Cmd.Dispose();
i get this error:
You tried to execute a query that does not include the specified expression '[Qty]-[Mly]' as part of an aggregate function.