cancel
Showing results for 
Search instead for 
Did you mean: 

Query For GRPO

Former Member
0 Kudos
68

Hi all,

i want a report for GRPO, the query that i have made is as mentioned below;

Select Docnum as Num, U_Gateno as Gate ,Docdate as Date, CardName as Party, U_Billno as Bill, DocDate as Date from opdn

Select Dscription as Item, Quantity as Qnty,unitMsr as Unit, Taxcode as vat from pdn1

now apart from these, i want the "unit price" and the "total" which are variables. Also can anyone please help me how to join these SQL to get a single row report?

Thanks in advance,

Joseph Antony

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Please try this onr:

Select T0.Docnum as Num, T0.U_Gateno as Gate ,T0.Docdate as Date, T0.CardName as Party, T0.U_Billno as Bill, T0.DocDate as Date, T1.Dscription as Item, T1.Quantity as Qnty, T1.unitMsr as Unit, T1.Taxcode as vat, T1.Price, T1.linetotal

from dbo.opdn T0

Inner Join dbo.pdn1 T1 on T1.DocEntry = T0.DocEntry

Thanks,

Gordon

Former Member
0 Kudos

Thanks Gordon and Neetu

Best Regards,

Joseph

Answers (1)

Answers (1)

Former Member
0 Kudos

SELECT OPDN.Docnum as Num, OPDN.U_Gateno as Gate ,OPDN.Docdate as Date, OPDN.CardName as Party, OPDN.U_Billno as Bill, OPDN.DocDate as Date,PDN1.Dscription as Item, PDN1.Quantity as Qnty,PDN1.unitMsr as Unit, PDN1.Taxcode as vat , PDN1.PriceBefDi as 'unit price',PDN1.Lineotal as 'Total'

FROM OPDN INNER JOIN

PDN1 ON OPDN.DocEntry = PDN1.DocEntry

regards,

Neetu