Slow Query
Hi,
Trying to Tune this Query
Explain plan show Full Table scan on
two Lines
1. ooha.order_number BETWEEN NVL(:p_sale_from,ooha.order_number) AND NVL(:p_sale_to,ooha.order_number) indexed column ooha.order_number
2. AND rcta.trx_number BETWEEN NVL(:p_inv_from,rcta.trx_number) AND NVL(:p_inv_to,rcta.trx_number) indexed column rcta.trx_number
SELECT DISTINCT rcta.trx_date
,rctt.attribute1
,rcta.customer_trx_id
,ooha.header_id
,ooha.invoice_to_org_id
,ooha.salesrep_id
,oola.line_id
,oola.inventory_item_id
,ottt.transaction_type_id
,ottt.name
, rcta.trx_number
Trying to Tune this Query
Explain plan show Full Table scan on
two Lines
1. ooha.order_number BETWEEN NVL(:p_sale_from,ooha.order_number) AND NVL(:p_sale_to,ooha.order_number) indexed column ooha.order_number
2. AND rcta.trx_number BETWEEN NVL(:p_inv_from,rcta.trx_number) AND NVL(:p_inv_to,rcta.trx_number) indexed column rcta.trx_number
SELECT DISTINCT rcta.trx_date
,rctt.attribute1
,rcta.customer_trx_id
,ooha.header_id
,ooha.invoice_to_org_id
,ooha.salesrep_id
,oola.line_id
,oola.inventory_item_id
,ottt.transaction_type_id
,ottt.name
, rcta.trx_number
0