1
근무한 테이블에 열을 추가하는 스크립트가 있습니다.Alter View에서 열을 인식하지 못합니다.
나는 열
Msg 207, Level 16, State 1, Procedure UniqueTempDispositions, Line 76
Invalid column name 'servicerequestid'.
Msg 207, Level 16, State 1, Procedure UniqueTempDispositions, Line 47
Invalid column name 'servicerequestid'.
Msg 207, Level 16, State 1, Procedure MergeDispositions, Line 54
Invalid column name 'ServiceRequestID'.
Msg 207, Level 16, State 1, Procedure NonPIICachedDispositions, Line 18
Invalid column name 'ServiceRequestID'.
어떤 이유
을 인정하지 않기 때문에 스크립트가 실패 새로운 열이 뷰를 변경하는 스크립트를 실행? 내가 놓친 게 있니?저는 서버를 시작하고 중지 했으므로 아무 소용이 없습니다. ORIGINAL SCRIPT :
use DispositionReporting
go
drop view dbo.UniqueTempDispositions
go
create view
dbo.UniqueTempDispositions
as
SELECT QuotaGroup, Country, ServiceGroup, Language, ContactChannel, TrackingID, CONVERT(DATETIME, CaseClosedDate) AS casecloseddate, MSFTRep, CustEmail,
CustPhone, CustomerName, ProductFamily, ProductSubType, CONVERT(DATETIME, CandidateReceivedDate) AS candidatereceiveddate, CONVERT(INT, SurveyMode)
AS surveymode, CONVERT(DATETIME, SurveyWaveStartDate) AS surveywavestartdate, CONVERT(DATETIME, SurveyInvitationDate) AS surveyinvitationdate,
CONVERT(DATETIME, SurveyReminderDate) AS surveyreminderdate, CONVERT(DATETIME, SurveyCompleteDate) AS surveycompletedate, CONVERT(DATETIME,
OptOutDate) AS optoutdate, CONVERT(DATETIME, SurveyWaveEndDate) AS surveywaveenddate, CONVERT(INT, DispositionCode) AS dispositioncode, SurveyName,
SurveyVendor, COUNT(*) AS countofunique, BusinessUnitName, UploadId, MIN(LineNumber) AS LineNumber, BusinessUnitSubgroup, ServiceRequestID
FROM DispositionReporting.dbo.tempDispositions AS td
GROUP BY QuotaGroup, Country, ServiceGroup, Language, ContactChannel, TrackingID, CONVERT(DATETIME, CaseClosedDate), MSFTRep, CustEmail, CustPhone,
CustomerName, ProductFamily, ProductSubType, CONVERT(DATETIME, CandidateReceivedDate), CONVERT(INT, SurveyMode), CONVERT(DATETIME,
SurveyWaveStartDate), CONVERT(DATETIME, SurveyInvitationDate), CONVERT(DATETIME, SurveyReminderDate), CONVERT(DATETIME, SurveyCompleteDate),
CONVERT(DATETIME, OptOutDate), CONVERT(DATETIME, SurveyWaveEndDate), CONVERT(INT, DispositionCode), SurveyName, SurveyVendor, BusinessUnitName,
UploadId, BusinessUnitSubgroup, ServiceRequestID
go
exec sp_refreshview 'dbo.UniqueTempDispositions'
go
죄송합니다, 작동하지 않습니다. –
실행중인 스크립트를 보여주세요. – SQLMenace