名称或代码在系统中已被使用" (错误代码:3604 E14H) Fdetail:列名'F3001'无效
KIS專業版
--修正核算項目關系
select * from t_itemdetail
exec sp_cleanitemdetailv
GO
update a set a.fdetailcount=b.Fcount
from t_itemdetail a join (select Fdetailid,count(*) as Fcount from t_itemdetailv where fitemid=-1 group by Fdetailid) b 
on a.fdetailid=b.fdetailid where a.fdetailcount<>b.Fcount
--修正核算項目關系完
--原因分析
--丟失F列,還需要進行F列的補回,t_itemdetail表中缺少列F3001
--解決方案
--補回此列,如果有數據發生還要補回數據
If Not Exists(Select c.Name from syscolumns c,sysobjects o
where c.Id=o.Id and c.name='F3001' and o.name='t_ItemDetail')
Begin
Alter Table t_ItemDetail Add F3001 int not null default(0)
Create Index ix_ItemDetail_3001 On t_ItemDetail(F3001)
END
其他
1、憑證過賬時系統提示:名稱或代碼在系統中已經被使用 
錯誤代碼:3604(E14H) 
Source :Microsoft OLE DB Provider for SQL Server 
Detail :在結果列的列表中多次出現列名 'F8' 
執行語句校正即可 
update d set d.fdetailcount=v.fcount 
from t_ItemDetail d, 
(select fdetailid,count(*) fcount from t_ItemDetailv where fitemid=-1 group by fdetailid ) v 
where d.fdetailid=v.fdetailid 
不同的賬套,可能會提示不同的列名,如F1等,請變通執行 
錯誤原因:核算項目橫表t_itemdetail的核算項目類別數目和科目掛的核算項目數目不一致 
2、在查詢科目余額表并選擇包括核算項目時,系統提示: 
名稱或代碼在系統中已被使用 
錯誤代碼:3604(E14H) 
Fdetail:列名'F3001'無效 
補回此列,如果有數據發生還要補回數據 
If Not Exists(Select c.Name from syscolumns c,sysobjects o 
where c.Id=o.Id and c.name='F3001' and o.name='t_ItemDetail') 
Begin 
Alter Table t_ItemDetail Add F3001 int not null default(0) 
Create Index ix_ItemDetail_3001 On t_ItemDetail(F3001) 
END 
如果還存在其他列名無效,參照修改上述SQL中的列名后,進行添加。 
錯誤原因:在t_itemdetail表中缺少列F3001 
3、錄入憑證時提示錯誤代碼:3604(E14H), Source :Microsoft OLE DB Provider for SQL Server Detail :分布式事務已完成。請將此會話登記到新事務或 NULL 事務中 
此問題是由憑證最大內碼號超過2147483647造成的,請參考以下SQL處理 
select distinct(fvoucherid) AS Foldid,IDENTITY(int,1,1) as fnewid into #tmpa from t_voucher----建立新舊憑證內碼對應關系 
update a set a.fvoucherid=b.fnewid from t_voucher a , #tmpa b where a.fvoucherid=b.folded-----用新內碼替換舊內碼 
update a set a.fvoucherid=b.fnewid from t_voucherentry a , #tmpa b where a.fvoucherid=b.foldid 
update t_identity set fnext=(select max(fvoucherid) from t_voucher)+1 where fname='t_voucher'
總結
以上是生活随笔為你收集整理的名称或代码在系统中已被使用" (错误代码:3604 E14H) Fdetail:列名'F3001'无效的全部內容,希望文章能夠幫你解決所遇到的問題。
 
                            
                        - 上一篇: 安装IIS
- 下一篇: css3 图片放大缩小闪烁效果
