hi,
i would like to include OCQG GroupName to the following query.
SELECT
T0.DocDate as 'Posting Date',
T0.DocNum as 'AR Invoice Number',
T0.CardName,
T3.SlpName,
T0.DocDate as 'Payment Date',
T1.DocNum as 'Incoming Payment Number ',
T0.DocTotal as 'AR Invoice Total',
T1.TrsfrSum,
T1.CashSum,
T1.CheckSum,
T2.CheckNum as 'Cheque Number'
FROM OINV T0
LEFT JOIN ORCT T1 ON T0.ReceiptNum = T1.DocEntry
LEFT JOIN RCT1 T2 ON T1.DocNum = T2.DocNum
Left Join OSLP T3 ON T3.SlpCode= T0.SlpCode
where T0.DocDate >='[%0]' and T0.DocDate <='[%1]'