내 전체 코드입니다 : 난 항상 @Avg_transaction_Per_CSR을 얻고있다나누기 두 개의 숫자 여기
declare @total_csr as int
declare @total_Transaction as int
declare @Avg_days_Open as decimal(18,8)
Declare @Avg_transaction_Per_CSR as int
SELECT @total_csr = COUNT(*) FROM [APMRS_RG2].[dbo].pdmmast p where Plan_Num in ('510') and
MONTH(p.Statdate) = @month and YEAR(p.statdate) = @Year
---- Total Transactions --------
SELECT @total_Transaction = SUM(cast(transaction_count as int)) FROM [APMRS_RG2].[dbo].pdmmast p where Plan_Num in ('510') and
MONTH(p.Statdate) = @month and YEAR(p.statdate) = @Year
---- AVG Transaction Per CSR
select @Avg_transaction_Per_CSR = CAST(@total_Transaction as decimal(18,8))/CAST(@total_csr as decimal(18,8))
0
예는 다음과 같습니다 @@ total_Transaction = 5 @Total_CSR = 26
의 종류,'@의 opendays'는 어떤 데이터 유형을 의심? – Lamak
오픈 일의 유형? –
무엇을 말하지 않습니까? – scsimon