好的,当我尝试执行此过程时出现此错误。问题是我并不想在任何时候转换成一点点。至少不是故意的。我现在有点难过。
Declare @AValue varchar(max)
set @AValue = (SELECT Value
FROM dbo.Tbl
WHERE Name=@FILE
AND Value LIKE (CAST(@MODID as varchar(15))+'|%'))
set @AValue = PARSENAME(REPLACE(@AValue, '|', '.'), 1) -- Hack way to parse.
INSERT INTO dbo.Tbl
(
Name,
Value,
Type,
CDT,
UDT,
Active,
User
)
VALUES
(
'Agreement',
(CAST(@MODID AS varchar(15)) + '|' + @AValue),
'Download',
GETDATE(),
GETDATE(),
1,
@USER
)