Chinaunix首页 | 论坛 | 博客
  • 博客访问: 1840319
  • 博文数量: 334
  • 博客积分: 11301
  • 博客等级: 上将
  • 技术积分: 3452
  • 用 户 组: 普通用户
  • 注册时间: 2006-10-18 10:19
个人简介

路虽弥,不行不至;事虽少,不做不成。

文章分类

全部博文(334)

文章存档

2013年(4)

2012年(19)

2011年(27)

2010年(71)

2009年(45)

2008年(15)

2007年(84)

2006年(69)

分类: Oracle

2010-07-09 10:22:53

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);
阅读(1372) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~