销售出库单对接思路(中间库mysql)
1.传递前先检查下finterid
select fmaxnum from ICMaxNum where FTableName='icstockbill'
将当前最大值fmaxnum存在中间库某个地方
2.程序中数据库关闭自动提交,事务设置TRANSACTION_READ_UNCOMMITTED:未提交读
2.1查询当前要传递的单据是否存在kis旗舰版中
select * from icstockbill where fbillno='单号'
存在则跳过,不存在则继续下一步
2.2 查询供应链当前年度,用于后续单据赋值
select FValue from t_SystemProfile where FCategory='IC' and FKey='CurrentYear'
2.3查询供应链当前期间,用于后续单据赋值
select FValue from t_SystemProfile where FCategory='IC' and FKey='CurrentPeriod'
2.4查询当前期间是否关帐 0未关 1关,,用于判断是否关账,关账则不再同步
select FValue fr