Need Query [message #378082] |
Sun, 28 December 2008 09:38 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
mnraju999
Messages: 2 Registered: December 2008 Location: Hyderabad
|
Junior Member |
![raju_mandala](/forum/theme/orafaq/images/yahoo.png)
|
|
Hi Friends,
some one can help to get one query with below conditons.
we have an issue : some of sales order lines item Unit Selling Price not matching with RMA SO line Unit Selling Price.
now need a query to find out such cases.
columns needed: SO#,line#,item,USP
need sales order number which are having RMA,but some of lines which are having discripancy in SO line item USP and RMA SO line USP for same item. i need the query for these discripancey so llines,item_type sould be Return.
Thanks for the help in advance.
|
|
|
Re: Need Query [message #378170 is a reply to message #378082] |
Mon, 29 December 2008 03:47 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) |
![](/forum/images/custom_avatars/45399.jpg) |
vamsi kasina
Messages: 2112 Registered: October 2003 Location: Cincinnati, OH
|
Senior Member |
|
|
Got it through PM...
Here are the table details.
Oe_order_headers
Oe_order_lines
OE_TRANSACTION_TYPES_TL
I have prepared below query but is not helping me
SELECT OOLV.order_number ORDER_NUMBER,
OOlV.line_number LINE_NUMBER,
OOLV.UNIT_SELLING_PRICE
FROM OE_ORDER_LINES_V OOLV,
OE_LINE_TYPES_V OLTV,
OE_TRANSACTION_TYPES_TL OTTT
WHERE OTTT.TRANSACTION_TYPE_ID=OOLV.ORDER_TYPE_ID
AND OLTV.LINE_TYPE_ID=OOLV.LINE_TYPE_ID
AND TRUNC (OOLV.CREATION_DATE) BETWEEN '01-JAN-2008'
AND '30-DEC-2008'
AND oolv.unit_selling_price <> (SELECT a.unit_selling_price
FROM OE_ORDER_LINES_V a,
oe_transaction_types_all b
WHERE b.TRANSACTION_TYPE_ID = a.order_type_id
AND b.ORDER_CATEGORY_CODE = 'RETURN'); Please check abow query , your help is great appreciated.
Thanks
Nagaraju
|
|
|