Is my string a number?

I have been recently devoting a-lot of time answering questions on STACKOVERFLOW. Many times, you are just helping and/or teaching younger SQL Server developers and/or administrators the tricks of the trade. Sometimes you come across a GEM, a question that you can blog about so that when they are asked again, you have a well constructed answer. One classic questions asked by new database developers is whether or not the user input is a number? I thought it was an excellent opportunity to review what tools are available given a…

Conversion Functions – TRY_CAST()

I am going to make headway on my series of articles (tidbits) on type conversion functions available in the Transaction SQL (T-SQL) language. One analogy of a data type conversion is apply the correct action to change the physical form of water (H2O). You can convert water to ice by cooling it. You can convert water to vapor by heating it. However, the chemical composition of water is still the same! Information is stored in a database as rows in a table. Each field in a table is defined with…