AR transactions should be created on 6-JUL-2010,in fact they were generated on 25-JUN-2010. Because the SHIP_DATE_ACTUAL is on 25-JUN-2010.
--------------------------------------------------------------------------------
--Original date: TRX_DATE=25-JUN-2010,GL_DATE=25-JUN-2010,DUE_DATE=25-JUL-2010
--------------------------------------------------------------------------------
SELECT * FROM AR.RA_CUSTOMER_TRX_ALL WHERE TRX_NUMBER IN ('905911','905912') AND SET_OF_BOOKS_ID=89
--TRX_DATE,SHIP_DATE_ACTUAL
SELECT * FROM AR.RA_CUSTOMER_TRX_LINES_ALL WHERE CUSTOMER_TRX_ID IN (9849489,9849490)
SELECT * FROM AR.RA_CUST_TRX_LINE_GL_DIST_ALL WHERE CUSTOMER_TRX_ID IN (9849489,9849490)
--GL_DATE
SELECT * FROM AR.AR_PAYMENT_SCHEDULES_ALL WHERE CUSTOMER_TRX_ID IN (9849489,9849490)
--DUE_DATE
Solution:
-----------------------------------------------------------------------------
UPDATE AR.RA_CUSTOMER_TRX_ALL
SET TRX_DATE = TRUNC(SYSDATE - 2)
WHERE TRX_NUMBER IN ('905911','905912')
AND SET_OF_BOOKS_ID = 89;
ALTER TRIGGER ra_cust_trx_line_gl_dist_bri DISABLE;
UPDATE AR.RA_CUST_TRX_LINE_GL_DIST_ALL
SET GL_DATE = TRUNC(SYSDATE - 2)
WHERE CUSTOMER_TRX_ID IN (9849489,9849490);
ALTER TRIGGER ra_cust_trx_line_gl_dist_bri ENABLE;
UPDATE AR.AR_PAYMENT_SCHEDULES_ALL
SET TRX_DATE = TRUNC(SYSDATE - 2),
GL_DATE = TRUNC(SYSDATE - 2),
DUE_DATE = TRUNC(SYSDATE + 28)
WHERE CUSTOMER_TRX_ID IN (9849489,9849490);
阅读(1377) | 评论(0) | 转发(0) |