cancel
Showing results for 
Search instead for 
Did you mean: 

Crystal Drill-Down not working in SAP

Former Member
0 Kudos

Hello all,

I have created a Crystal report based on the below query and grouped it by the Supplier Name such that the report displays the supplier name and total stock value. I further executed a drill-down such that if a user wants to view the individual items he/she can drill-down by clicking on the supplier. The report works perfectly in Crystal report, but when I run it in SAP, the drill-down functionality is not working. I have made other drill-down reports that work well in SAP

SELECT T2.[CardCode], T2.[CardName], T1.[ItemCode], T1.[SuppCatNum], T1.[FrgnName], T0.whscode,T0.[OnHand], T0.[AvgPrice], (T0.[OnHand]*T0.[AvgPrice]) Value FROM OITW T0  INNER JOIN OITM T1 ON T0.ItemCode = T1.ItemCode INNER JOIN OCRD T2 ON T1.CardCode = T2.CardCode WHERE T2.[CardType] ='s' and  T0.[OnHand] >'0'

Any help will be highly appreciated. Thank you.

Regards,

Henry

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

The big difference is: BP Name is part of the OINV and ORIN table. OITW has no such entry.

Former Member
0 Kudos

Thanks Gordon, so, do you think there is a workaround?

Former Member
0 Kudos

Try CardCode drill down instead.

Former Member
0 Kudos

Still not drilling down in SAP, works in Crystal just like the original report

Former Member
0 Kudos

I am afraid you may not be able to get the drill-down in B1 if you include OITW in the query.

Former Member
0 Kudos

Hi Henry,

For the other working report, what tables in?

Thanks,

Gordon

Former Member
0 Kudos

Hi Gordon,

the other query is as below:

SELECT distinct T3.[CardCode], T3.[CardName],T2.SuppCatNum,T1.Dscription, sum(T1.Quantity)Quantity , sum(T1.[LineTotal]) Sales FROM OINV T0  INNER JOIN INV1 T1 ON T0.DocEntry = T1.DocEntry INNER JOIN OITM T2 ON T1.ItemCode = T2.ItemCode INNER JOIN OCRD T3 ON T2.CardCode = T3.CardCode WHERE T0.[DocDate] >={?from} and  T0.[DocDate] <={?to} GROUP BY T3.[CardCode], T3.[CardName],T2.SuppCatNum,T1.Dscription

union all

SELECT distinct T3.[CardCode], T3.[CardName],T2.SuppCatNum,T1.Dscription, sum(T1.Quantity)Quantity, sum(T1.[LineTotal])*-1 Sales FROM ORIN T0  INNER JOIN RIN1 T1 ON T0.DocEntry = T1.DocEntry INNER JOIN OITM T2 ON T1.ItemCode = T2.ItemCode INNER JOIN OCRD T3 ON T2.CardCode = T3.CardCode WHERE T0.[DocDate] >={?from} and  T0.[DocDate] <={?to} GROUP BY T3.[CardCode], T3.[CardName],T2.SuppCatNum,T1.Dscription

Thank you and regards,

Henry