帆软使用教程

本文是一份详尽的帆软软件使用教程,涵盖了从基础操作到高级应用的各个层面,帮助用户快速掌握帆软工具的使用技巧和最佳实践。

在这里插入图片描述
2.
在这里插入图片描述
3.
在这里插入图片描述
4.
在这里插入图片描述
5.
在这里插入图片描述
6.
在这里插入图片描述

${if(AGENCY_CODE = '',
            "",
            "and AGENCY_CODE in ('" + REPLACE(AGENCY_CODE, ",", "','") + "')") }

在这里插入图片描述
在这里插入图片描述
剩下的那个and agency_code就是sql里你写的where条件 你这个改成mof div code就可以

select t1.收入分类科目代码,t1.账套名称,t1.乡镇类,t1.乡镇款,t1.乡镇项,t1.乡镇子项,t.income_sort_name,t.income_sort_code,t1.code1,t1.code2,t1.code3,t1.code4,t1.会计科目代码,t1.收入分类科目名称 from 
(select 
c.income_sort_code as 收入分类科目代码,
   a.name as 账套名称,
   c.income_sort_name as 收入分类科目名称,a.code,substr(c.account_cls_code, 1, 4) as 会计科目代码,w.code1 as code1,
   w.code2 as code2,w.code3 as code3,w.code4 as code4,c.vou_det_id,
  sum ((c.cre_money))over(partition by w.code1,a.name,substr(c.account_cls_code, 1, 4) ) as 乡镇类,
sum ((c.cre_money))over(partition by w.code2,a.name,substr(c.account_cls_code, 1, 4) ) as 乡镇款,
sum ((c.cre_money))over(partition by w.code3,a.name,substr(c.account_cls_code, 1, 4) ) as 乡镇项,
sum ((c.cre_money))over(partition by w.code4,a.name,substr(c.account_cls_code, 1, 4) ) as 乡镇子项
    from CZ_GLDATA23.GLF_VOU_DETAIL c
   left join  CZ_GLDATA23.GLF_VOU_HEAD b
     on c.vou_id=b.vou_id  
     left join  cz_element.gap_book_set a 
     on   a.id = b.set_id,
     cz_element.bas_income_sort w 
      where c.set_year = '2023'
      AND substr(c.account_cls_code, 1, 4) in ('6001', '6002', '6003')
       and c.is_deleted <> 1
      and b.is_deleted <> 1
       and a.is_deleted <> 1 
       ${if(treeComboBoxEditor1 = '',
            "",
            "and c.mof_div_code in ('" + REPLACE(treeComboBoxEditor1, ",", "','") + "')") }
       -- treeComboBoxEditor1
       and w.income_sort_code=c.income_sort_code
       and b.make_date between '${start_time}' and '${end_time}'
       --and b.make_date between 2023-01-01 and 2023-03-14
       group by a.name,c.income_sort_code,c.income_sort_name,c.vou_det_id,c.cre_money ,a.code,substr(c.account_cls_code, 1, 4),w.code1,w.code2,w.code3,w.code4
        order by c.income_sort_code) t1
       

  right join (select distinct w.income_sort_code,w.income_sort_name
               from cz_element.bas_income_sort w 
              where length(income_sort_code) = 9 or length(income_sort_code) = 7 or length(income_sort_code) = 5 or length(income_sort_code) = 3) t 
  on t.income_sort_code = t1.收入分类科目代码
  order by income_sort_code

在这里插入图片描述
在这里插入图片描述
在这里插入图片描述
在这里插入图片描述

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值