Foxtable(狐表)用户栏目专家坐堂 → [推荐] 将 numeric 转换为数据类型 numeric 时出现算术溢出错误。


  共有2261人关注过本帖树形打印复制链接

主题:[推荐] 将 numeric 转换为数据类型 numeric 时出现算术溢出错误。

帅哥哟,离线,有人找我吗?
2900819580
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:六尾狐 帖子:1347 积分:9817 威望:0 精华:0 注册:2015/6/30 8:46:00
[推荐] 将 numeric 转换为数据类型 numeric 时出现算术溢出错误。  发帖心情 Post By:2019/5/4 10:36:00 [只看该作者]

.NET Framework 版本:2.0.50727.5485
Foxtable 版本:2018.3.9.1
错误所在事件:
详细错误信息:
将 numeric 转换为数据类型 numeric 时出现算术溢出错误。

 

数据库视图代码

SEL ECT DISTINCT
                      a.任务单号, a.车间, a.组别, a.子阶ID, SUM(a.需求数量) AS 需求数量, a.状态, a.红蓝单, a.制单, a.审核, a.仓库ID, a.单据类型, b.FBillNo AS 单据编号,
                      c.FNumber AS 物料代码, c.FName AS 物料名称, c.FModel AS 规格型号, e.FName AS 单位, f.FNote AS 库位号, k.负责人, k.仓库名称, w.排产单号,
                      (CASE WHEN a.状态 = 0 THEN NULL ELSE 'Y' END) AS 审核标志,
                          (SEL ECT     SUM(实发数量) AS Expr1
                            FROM          dbo.生产发料单
                            WHERE      (任务单号 = a.任务单号) AND (物料ID = a.子阶ID) AND (车间 = a.车间) AND (组别 = a.组别)) AS 已发数量,
                          (SEL ECT     CAST(SUM(FQty) AS decimal(5, 0)) AS Expr2
                            FROM          AIS20181207194554.dbo.ICInventory
                            WHERE      (FItemID = a.子阶ID) AND (FStockID IN (252, 253, 14826, 254, 255, 256, 39528))) AS 库存数量
FROM         dbo.生产任务单 AS a LEFT OUTER JOIN
                      dbo.仓库负责人 AS k ON k.序号 = a.仓库ID LEFT OUTER JOIN
                      dbo.订单视图 AS w ON w.任务单号 = a.任务单号 LEFT OUTER JOIN
                      AIS20181207194554.dbo.SEOrder AS b ON a.订单ID = b.FInterID LEFT OUTER JOIN
                      AIS20181207194554.dbo.t_ICItemCore AS c ON a.子阶ID = c.FItemID LEFT OUTER JOIN
                      AIS20181207194554.dbo.t_ICItemBase AS d ON a.子阶ID = d.FItemID LEFT OUTER JOIN
                      AIS20181207194554.dbo.t_MeasureUnit AS e ON d.FUnitID = e.FItemID LEFT OUTER JOIN
                      AIS20181207194554.dbo.t_ICItemMaterial AS f ON a.子阶ID = f.FItemID
WHERE     (a.状态 = 0)
GROUP BY a.任务单号, a.车间, a.组别, a.子阶ID, a.状态, a.红蓝单, a.制单, a.审核, a.仓库ID, b.FBillNo, c.FNumber, c.FName, c.FModel, e.FName, f.FNote, k.负责人, w.排产单号,
                      k.仓库名称, a.单据类型, a.序号


图片点击可在新窗口打开查看此主题相关图片如下:无标题.png
图片点击可在新窗口打开查看
[此贴子已经被作者于2019/5/4 10:39:27编辑过]

 回到顶部
帅哥哟,离线,有人找我吗?
有点甜
  2楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:版主 帖子:85326 积分:427815 威望:0 精华:5 注册:2012/10/18 22:13:00
  发帖心情 Post By:2019/5/4 11:57:00 [只看该作者]


 回到顶部