English

速达软件
     
当前位置:速达软件 >> 技术支持 >> 浏览文章

3.76现金银行报表中的期初数据不能从出纳账户犯填。

发布日期:2012年03月16日 浏览次数: 作者:佚名  
查询分析器中运行该脚本文件。 delete ac_accountbalance declare @nyear int,@nmonth int,@accountid int declare account_cursor cursor local forward_only static read_only for select DISTINCT accountid from aa_mscash where accountid not in (select accountid from ac_accountbalance) open account_cursor fetch next from account_cursor into @accountid; while @@fetch_status = 0 begin select @nyear=min(nyear) from aa_mscash where accountid=@accountid select @nmonth=min(nmonth) from aa_mscash where accountid=@accountid and nyear=@nyear insert into ac_accountbalance(accountid,moneyid,balance,balinit,lcbalance,lcbalinit) select accountid,moneyid,fbmbala,fbmbala,bmbala,bmbala from aa_mscash where accountid=@accountid and nyear=@nyear and nmonth=@nmonth fetch next from account_cursor into @accountid end close account_cursor; deallocate account_cursor;
  
 
上一篇:将numeric转换为数据类型numeric时发生算术溢出错误 下一篇:在成品-约当产量比率法