问题版本: | 34-用友通标准版10.1 | 问题模块: | 1-总账 | 所属行业: | 0-通用 | 问题状态: | 1-用友渠道员工帐户 | 关 键 字: | ‘未审核的凭证允许记账’不起做用 | 适用产品: | 1 | 补 丁 号: | | 开放状态: | 2-用友渠道员工帐户 | 原问题号: | | 提交时间: | 2006-12-25 14:46:00 | 问题名称: | ‘未审核的凭证允许记账’不起做用 | 问题现象: | 初始化时将"未审核的凭证允许记账"已打钩,数据库里的记录也是对的,但在记账时,出现"有未审核凭证,不能汇总记账凭证",点"确定"后出现"无可记账凭证 | 原因分析: | 是升级过程中没有执行关于“未审核也可以记帐”的相关语句。 | 解决方案: | 重新执行如下语句: ALTER Proc GL_P_JZA(@iPer tinyint = 11, @ccash tinyint =1, @tcond varchar(5000)= '') AS SET NOCOUNT On declare @ss varchar(8000) --ll Tong2005B declare @Checkflag varchar(20) set @Checkflag = (SELECT cvalue FROM AccInformation WHERE cSysID='GL' AND cName='bNotCheckJz') ------------------------------ Delete From GL_mpostcond1 if @ccash=0 begin --ll Tong2005B if @Checkflag = 'False' set @ss='SELECT iperiod,isignseq,ino_id From gl_accvouch where ibook=0 and iperiod= '+convert(char,@iPer,0) +(case when @tcond='' then '' else ' and (' + @tcond + ')' end)+' and (not (ccheck is null) and iflag is null or ccheck is null and iflag=1) GROUP BY iperiod,isignseq,ino_id' else set @ss='SELECT iperiod,isignseq,ino_id From gl_accvouch where ibook=0 and iperiod= '+convert(char,@iPer,0) +(case when @tcond='' then '' else ' and (' + @tcond + ')' end)+' and (iflag is null or ccheck is null and iflag=1) GROUP BY iperiod,isignseq,ino_id' ----------------------------- Insert GL_mpostcond1 exec (@ss) End Else begin if not object_id('tempdb..GL_jztmp') is null drop table tempdb..GL_jztmp --ll Tong2005B if @Checkflag = 'False' set @ss='SELECT isignseq,ino_id,1 as zt into tempdb..GL_jztmp FROM gl_accvouch inner join code ON gl_accvouch.ccode = code.ccode where ibook=0 and iperiod= '+convert(char,@iPer,0)+(case when @tcond='' then '' else ' and (' + @tcond + ')' end) +' and ((code.bbank ^ code.bcash) =1) and ((not (ccheck is null)) and (ccashier is null)) GROUP BY isignseq,ino_id Union SELECT isignseq,ino_id,0 as zt From gl_accvouch where ibook=0 and iperiod= '+convert(char,@iPer,0) +(case when @tcond='' then '' else ' and (' + @tcond + ')' end)+' and (not (ccheck is null) and iflag is null or ccheck is null and iflag=1) GROUP BY isignseq,ino_id' else set @ss='SELECT isignseq,ino_id,1 as zt into tempdb..GL_jztmp FROM gl_accvouch inner join code ON gl_accvouch.ccode = code.ccode where ibook=0 and iperiod= '+convert(char,@iPer,0)+(case when @tcond='' then '' else ' and (' + @tcond + ')' end) +' and ((code.bbank ^ code.bcash) =1) and (ccashier is null) GROUP BY isignseq,ino_id Union SELECT isignseq,ino_id,0 as zt From gl_accvouch where ibook=0 and iperiod= '+convert(char,@iPer,0) +(case when @tcond='' then '' else ' and (' + @tcond + ')' end)+' and (iflag is null or ccheck is null and iflag=1) GROUP BY isignseq,ino_id' ------------------------------ exec (@ss) SELECT isignseq,ino_id,sum(zt) as zt1 into #gl_bookB from tempdb..GL_jztmp group by isignseq,ino_id set @ss='select '+convert(char,@iPer,0)+' as iperiod,isignseq,ino_id from #gl_bookB Where zt1 = 0 '+(case when @tcond='' then '' else ' and (' + @tcond + ')' end) insert GL_mpostcond1 exec (@ss) End |
|
|