Convert() function in SqlServer

Syedshakeer
Posted by Syedshakeer under Sql Server category on | Views : 2456
Convert() is used to convert a data from one data type to another data type.

declare @a varchar(2)

declare @b varchar(2)

set @a=10

set @b=20

Select COVERT(int,@a)+CONVERT(int,@b) as Result


OutPut:-

Result 

30

Comments or Responses

Login to post response