Customer list who have a balance
Dear All,
im trying to build a query that select the customer list & what currency they have
but it takes too much time , im not sure how i can optimize it because when i want to run it to select all customer and im dont know waht to do to remove the UNION & UNION ALL
the procedure is as below :
CREATE OR REPLACE PROCEDURE XX_CUST_CURLIST( P_ORG_ID number ,P_CUSTOMER_NUM char, p_currency_code char , P_TRX_FROM_DATE char ,P_TRX_TO_DATE char ) IS
cust_num varchar2(100);
cust_name varchar2(100);
cust_curr varchar2(100);
k number(38) :=0;