'I want to change the type of DB table field from number to text type I should use

I want to change the type of db table from number to text type I should use _ operator

sql


Solution 1:[1]

you can use

declare @a as int = 25

select cast (@a as nvarchar (255)) as example

for more details, you can read this - https://docs.microsoft.com/en-us/sql/t-sql/functions/cast-and-convert-transact-sql?f1url=%3FappId%3DDev15IDEF1%26l%3DEN-US%26k%3Dk(CONVERT_TSQL);k(sql13.swb.tsqlresults.f1);k(sql13.swb.tsqlquery.f1);k(MiscellaneousFilesProject);k(DevLang-TSQL)%26rd%3Dtrue&view=sql-server-ver15

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 MasterIT