Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

SAP Business One query generator

Hi, Everyone

We recently started using SAP and i'm trying to generate a report and i can use some help!

I want to export a list of all item master data and there parent & child items associated with it and the BP Catalog No. associated with each item and additional identifier for each of them.

Thanks, Sol

Tags:
replied

You can start from this:

With BOM (Parent,Child,Quantity,Level) As

(

Select P.Father Parent,P.Code Child, Quantity,0 Level

From ITT1 P

Where P.Father =  '[%0]'

Union All

Select c.Father,C.Code,C.Quantity,Level+1

From Itt1 C

  Inner join BOM B on c.Father=B.Child

)

Select B.Parent,B.Child,B.Quantity,B.Level

From BOM B Inner join OITM I On B.Child=I.ItemCode

Option (MAXRECURSION 99)

Regards

Kennedy

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question