Muy buenas tardes muchas gracias rmaeloy,gnzsoloyo me funciono de maravilla
una mas a mi cartilla de SQL
Código SQL:
Ver originalSELECT A.CardCode, A.CardName, A.DocNum, (SELECT SUM(B.Quantity * B.Price) AS tot FROM inv1 AS B WHERE A.docentry = B.DocEntry) - A.DiscSum AS ValorNeto
FROM oinv AS A
WHERE A.docNum = 30027
Cordial saludo
desde Bogota