SQL How to concatenate Integer with string on SQL

今日有朋友問我一個SQL問題
就是如何打數字 和Varchar合併在一起..
E.G.
我個有一個Varchar =’2011′
和一個數字20
DECLARE @VarcharText VARCHAR(10) = ‘2011’
DECLARE @InvValue INT = 12
當你寫 執行
SELECT “2011” + @InvValue

use CAST( as VARCHAR(10))
My friend has asked me a simple SQL question. which is: How to

Leave a Reply