商店数据提供程序返回的数据读取器没有足够的列用于请求的查询。 [英] The data reader returned by the store data provider does not have enough columns for the query requested.

查看:96
本文介绍了商店数据提供程序返回的数据读取器没有足够的列用于请求的查询。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

商店数据提供商返回的数据阅读器没有足够的列用于请求的查询。







The data reader returned by the store data provider does not have enough columns for the query requested.



Line 1553:            }
Line 1554:
Line 1555:            return base.ExecuteFunction<Nullable<global::System.Int32>>("SalaryMonthly", employeeIdParameter);
Line 1556:        }
Line 1557:









我的店铺流程









my store procedere


ALTER PROCEDURE [dbo].[SalaryMonthly]
@EmployeeId int
AS
declare @i int,@presentday int,@OneDaySalary int, @totalDay int,@NetSalary int,@Month int,@year int
set @totalDay=(select datediff(day, GETDATE(), dateadd(month, 1, GETDATE())))
set @presentday =(select PresentDay from TblAttendeceMonthly where EmployeeId=@EmployeeId)
set @OneDaySalary =(select salary from  TblSalary where EmploeeId=@EmployeeId)/@totalDay
set @NetSalary=@presentday * @OneDaySalary
set @Month=(SELECT DATEPART(MM, GETDATE()))
set @year=(SELECT DATEPART(YY, GETDATE()))
BEGIN
if @presentday is not null
begin
    insert into TblSalaryMonthly  values (@EmployeeId,@NetSalary,@Month,@year,@presentday,1,0,GETDATE(),null )
end
end


exec SalaryMonthly 41

推荐答案

这篇关于商店数据提供程序返回的数据读取器没有足够的列用于请求的查询。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆