update VS4TEmpTimeChk set TEtcSalaryPeriod=TEtcTSAPTEmTCode+'-'+
CAST(year(TEtcTSaPDate)AS NVARCHAR(4))+'-'+right('00'+cast(month(TEtcTSaPDate) AS NVARCHAR(2)),2)+'-'++right('00'+cast(day(TEtcTSaPDate)AS NVARCHAR(2)),2)
GO
update VS4TEmpActiveAmass set TEAASalaryPeriod=TEAATSAPTEmTCode+'-'+
CAST(year(TEAATSaPDate)AS NVARCHAR(4))+'-'+right('00'+cast(month(TEAATSaPDate) AS NVARCHAR(2)),2)+'-'++right('00'+cast(day(TEAATSaPDate)AS NVARCHAR(2)),2)
GO
update VS4TEmpAmassType set TEATSalaryPeriod=TEATTEmTCode+'-'+
CAST(year(TEATPaymentDate)AS NVARCHAR(4))+'-'+right('00'+cast(month(TEATPaymentDate) AS NVARCHAR(2)),2)+'-'++right('00'+cast(day(TEATPaymentDate)AS NVARCHAR(2)),2)
GO
update VS4TEmpSlipDoc set TEpsSalaryPeriod=TEpsTSAPTEmTCode+''+
CAST(year(TEpsTSaPDate)AS NVARCHAR(4))+'-'+right('00'+cast(month(TEpsTSaPDate) AS NVARCHAR(2)),2)+'-'++right('00'+cast(day(TEpsTSaPDate)AS NVARCHAR(2)),2)
GO

