壹佰网|ERP100 - 企业信息化知识门户

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 1677|回复: 9

compiere 由请购单创建采购定单出错

[复制链接]
发表于 2008/8/29 10:21:54 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。如果您注册时有任何问题请联系客服QQ: 83569622  。

您需要 登录 才可以下载或查看,没有帐号?注册

x
由请购单创建采购定单出错,帮忙看一下   附件 从请购单创建采购订单.bmp (279.05 KB) 2008-4-14 20:01
 楼主| 发表于 2008/8/30 23:20:07 | 显示全部楼层

郁闷.怎么没人解答

郁闷了,怎么没人帮忙解答呢?版主,你也不能帮忙看一下吗?
  
发表于 2008/9/1 21:22:59 | 显示全部楼层
有后台的错误信息吗?
发表于 2008/9/1 21:24:25 | 显示全部楼层
相关的信息都全了吗?
Price List, 供应商地址,...
 楼主| 发表于 2008/9/2 10:05:27 | 显示全部楼层

请看下面的信息

*** 2008-09-02 10:11:02.906 Compiere Log (CLogConsole) ***
10:11:02.906 Compiere.startup: Compiere(r) Release 3.0.2_2008-04-07 - Smart ERP
& CRM - (c) 1999-2008 Compiere (r); Implementation: 3.0.2 20080407-1758 - Compie
re China
10:11:02.906 Compiere.startup: Client zanmei/: G:\Compiere2 - Java
HotSpot(TM) Client VM 1.5.0_15-b04 - Windows 2003 5.2 Service Pack 2
10:11:04.281 Ini.loadProperties: C:\Documents and Settings\Administrator\Compier
e.properties #27
-----------> CConnection.getStatusEjbStub: jnp://zanmei:1099
- javax.naming.CommunicationException: Receive timed out [Root exception is jav
a.net.SocketTimeoutException: Receive timed out]
- {java.naming.provider.url=jnp://zanmei:1099, java.naming.factory.initial=org.
jnp.interfaces.NamingContextFactory, jnp.discoveryTimeout=2000, jnp.timeout=2000
, java.naming.factory.url.pkgs=org.jboss.naming.client, jnp.sotimeout=2000}
===========> DB.executeUpdate: INSERT INTO C_Order (AD_Client_ID,AD_Org_ID,AD_Us
er_ID,Bill_BPartner_ID,Bill_Location_ID,Bill_User_ID,C_BPartner_ID,C_BPartner_Lo
cation_ID,C_Currency_ID,C_DocTypeTarget_ID,C_DocType_ID,C_Order_ID,C_PaymentTerm
_ID,ChargeAmt,Created,CreatedBy,DateAcct,DateOrdered,DatePromised,DeliveryRule,D
eliveryViaRule,Description,DocAction,DocStatus,DocumentNo,FreightAmt,FreightCost
Rule,GrandTotal,InvoiceRule,IsActive,IsApproved,IsCreditApproved,IsDelivered,IsD
iscountPrinted,IsDropShip,IsInvoiced,IsPrinted,IsReturnTrx,IsSOTrx,IsSelected,Is
SelfService,IsTaxIncluded,IsTransferred,M_PriceList_ID,M_Warehouse_ID,PaymentRul
e,Posted,PriorityRule,Processed,Processing,SendEMail,TotalLines,Updated,UpdatedB
y) VALUES (11,11,103,114,109,103,114,109,100,126,0,1000007,106,0,TO_DATE('2008-0
9-02 10:11:51','YYYY-MM-DD HH24:MI:SS'),100,TO_DATE('2008-09-02','YYYY-MM-DD'),T
O_DATE('2008-09-02','YYYY-MM-DD'),TO_DATE('2008-09-02','YYYY-MM-DD'),'A','P','Re
quisition: 900001','PR','DR','800005',0,'I',0,'I','Y','N','N','N','N','N','N','N
','N','N','N','N','N','N',101,103,'P','N','5','N','N','N',0,TO_DATE('2008-09-02
10:11:51','YYYY-MM-DD HH24:MI:SS'),100) [SvrProcess_1220321511750] [11]
java.sql.SQLException: ORA-01400: cannot insert NULL into ("COMPIERE"."C_ORDER".
"SALESREP_ID")
; State=23000; ErrorCode=1400
        at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java
:125)
        at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:305)
        at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:272)
        at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:623)
        at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.
java:181)
        at oracle.jdbc.driver.T4CPreparedStatement.execute_for_rows(T4CPreparedS
tatement.java:543)
        at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStateme
nt.java:1028)
        at oracle.jdbc.driver.OracleStatement.doScrollExecuteCommon(OracleStatem
ent.java:3753)
        at oracle.jdbc.driver.OraclePreparedStatement.doScrollPstmtExecuteUpdate
(OraclePreparedStatement.java:8829)
        at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePrep
aredStatement.java:2886)
        at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePrepar
edStatement.java:2960)
        at org.compiere.util.CPreparedStatement.executeUpdate(CPreparedStatement
.java:215)
        at org.compiere.util.DB.executeUpdate(DB.java:840)
        at org.compiere.util.DB.executeUpdate(DB.java:747)
        at org.compiere.framework.PO.saveNewInsertSQL(PO.java:2770)
        at org.compiere.framework.PO.saveNew(PO.java:2619)
        at org.compiere.framework.PO.save(PO.java:2216)
        at org.compiere.process.RequisitionPOCreate.newOrder(RequisitionPOCreate
.java:297)
        at org.compiere.process.RequisitionPOCreate.newLine(RequisitionPOCreate.
java:368)
        at org.compiere.process.RequisitionPOCreate.process(RequisitionPOCreate.
java:261)
        at org.compiere.process.RequisitionPOCreate.doIt(RequisitionPOCreate.jav
a:121)
        at org.compiere.process.SvrProcess.startProcess(SvrProcess.java:91)
        at org.compiere.apps.ProcessCtl.startProcess(ProcessCtl.java:483)
        at org.compiere.apps.ProcessCtl.run(ProcessCtl.java:251)

-----------> DB.saveError: DBExecuteError - ORA-01400: cannot insert NULL into (
"COMPIERE"."C_ORDER"."SALESREP_ID")
[11]
-----------> MOrder.saveNewInsertSQL: [SvrProcess_1220321511750]Not inserted - C
_Order [11]
-----------> RequisitionPOCreate.startProcess: Cannot save Order [11]

[ 本帖最后由 zanmei2046 于 2008-9-2 10:13 编辑 ]
 楼主| 发表于 2008/9/2 10:06:10 | 显示全部楼层

版本是compiere3.0.2

版本是compiere3.0.2
发表于 2008/9/2 12:02:48 | 显示全部楼层
看不懂!
发表于 2008/9/2 14:14:56 | 显示全部楼层
看SQL是因为请购单中没有选择销售代表,导致采购单的销售代表为null导致错误

不过要看下请购单中是否选择了销售代表?如果选择了,请核查下生成采购单的过程是否给销售代表ID负值了。
 楼主| 发表于 2008/9/2 16:57:43 | 显示全部楼层

感谢herome的帮忙

谢谢herome
问题解决了.数据库中salesrep_id字段是不允许为空,而在申购时又没有这个字段
于是我把数据库中这个字段改为允许为空,就能成功生成采购定单了
zx0800 该用户已被删除
发表于 2009/8/5 14:45:27 | 显示全部楼层
提示: 作者被禁止或删除 内容自动屏蔽
您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|Archiver|小黑屋|手机版|壹佰网 ERP100 ( 京ICP备19053597号-2 )

Copyright © 2005-2012 北京海之大网络技术有限责任公司 服务器托管由互联互通
手机:13911575376
网站技术点击发送消息给对方83569622   广告&合作 点击发送消息给对方27675401   点击发送消息给对方634043306   咨询及人才点击发送消息给对方138011526

GMT+8, 2025/11/30 10:29 , Processed in 0.016403 second(s), 16 queries , File On.

Powered by Discuz! X3.4

Copyright © 2001-2020, Tencent Cloud.

快速回复 返回顶部 返回列表