Skip to Content
0
Former Member
Aug 21, 2015 at 10:16 AM

Serial No Management Query

14 Views

Hi,

I am trying to make a query report. My requirement is to generate list of all open Goods Return with its Item Serial NO.

I have tried to make the same with the below mentioned query but instead of throwing one single result its throwing repeated list.

Can any body tell me what relation I can get between between RPD1 and OSRN OR OSRI.

SELECT T2.DocNum,T2.CardCode,T2.CardName,T2.NumAtCard,T1.IntrSerial, T2.DocDueDate, T2.DocTotal,T2.DocStatus FROM SRI1 T0

INNER JOIN OSRI T1 ON T0.[SysSerial] = T1.[SysSerial]

INNER JOIN ORPD T2 ON T2.OBJTYPE=T0.BASETYPE

AND T2.DOCNUM=T0.BASENUM

INNER JOIN RPD1 T3 ON T2.[DocEntry] = T3.[DocEntry]

WHERE T0.[BaseType] =21

Where T2.DocNum = '300181'

Thanks and Regards

Chandan Lal