Closed. This question is not reproducible or was caused by typos . It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 6 days ago.
Improve this question
I want to add up a value in SQL Server but the first 0 is missing after adding it The following is an example of the code:
DECLARE @test1 VARCHAR(8)
DECLARE @test2 INT
SET @test2 = 1
SET @test1 = '06149' + @test2
SELECT @test1
Output: 6150
what I want is a result like this: 06150
2条答案
按热度按时间j91ykkif1#
Other Way(SQL Server):
lf5gs5x22#
I've found the answer: