列值在RDLC报告中出现Converison问题 [英] Column Values Converison issue in RDLC reports
本文介绍了列值在RDLC报告中出现Converison问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
@GroupId int,
@StartDate DATETIME = NULL,
@EndDate DATETIME = NULL,
@RegionCode varchar(30) = NULL
AS
BEGIN
DECLARE @AgencyTable TABLE (GpoId int, OfcId int, Total_Bills BIGINT, Bill_Value BIGINT, Commission BIGINT, Total_Amount BIGINT)
SET @EndDate = convert(datetime, convert(Varchar(12), @EndDate, 106) + ' 23:59:59PM')
--1. Billing Summary By GPO Name
INSERT @AgencyTable (GpoId, OfcId, Total_Bills, Bill_Value, Commission, Total_Amount)
SELECT bil.GroupId, Bil.SubOfficeId , isnull(COUNT(Bil.ConsumerNumber),0) --AS Total_Bills,
,ISNULL(SUM(Bil.C_Amount),0) --AS Bill_Value,
,ISNULL(SUM(Bil.Commission),0) --AS Commission,
,ISNULL(SUM(Bil.C_Amount),0) - ISNULL(SUM(Bil.Commission),0) --AS Total_Amount
FROM BillTxnSO as Bil inner join pp_offices ofc On bil.GroupId = ofc.Group_Id and bil.SubOfficeId = ofc.OfficeCode
Where bil.GroupId = @GroupId AND TransDate BETWEEN @StartDate AND @EndDate
Group by bil.GroupId, Bil.SubOfficeId
--select * from @AgencyTable
SELECT ofc.OfficeName as SubOffice_Name, isnull(gpo.Total_Bills,0)as Total_Bills , isnull(gpo.Bill_Value,0)as Bill_Value , isnull(gpo.Commission,0) as Commission, isnull(gpo.Total_Amount,0) as Total_Amount
FROM @AgencyTable gpo
INNER JOIN pp_offices ofc On ofc.Group_Id = gpo.GpoId and gpo.OfcId = ofc.OfficeCode
ORDER BY ofc.OfficeName
END
................ .................................................. ................ <无线电通信/>
此查询在报告生成中正常工作但在报告查看器中我得到了SubOffice_Name,即SubOffice_Name而不是ofc.officeName。任何人都可以帮助我这方面
..................................................................................
This Query working fine in report generation but in report viewer i got the SubOffice_Name as it is i.e "SubOffice_Name" in stead of ofc.officeName.Can anyone help me in this regard
推荐答案
我已经完成了DataSet的问题
I have done it there is a problem of DataSet
这篇关于列值在RDLC报告中出现Converison问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文