SQL Server Exception Handling Part 12This post is a continuation of Part 11. We have a table called dbo.Reports. We do not want […] March 23, 2017 in SQL Server tagged error / sql / exception / SQL Server Exceptions by Mike
SQL Server Exception Handling IntroductionThis post is part of a series of posts on exception handling in SQL Server. This post includes […] March 17, 2017 in SQL Server tagged handling / error / server / sql / exception / introduction / SQL Server Exceptions by Mike
SQL Server AdventureWorks2014 InstallationYou may wish to install a sample database from Microsoft called Adventure Works 2014. The reason you may […] March 5, 2017 in SQL Server tagged sql / sample by Mike
SQL Server Exporting Data Programatically with bcp and xp_cmdshellMany times you may find that you need to take some data in a table or tables and […] February 28, 2017 in SQL Server tagged file / sql / bcp / xp_cmdshell / output by Mike
SQL Server Exporting a Table to a Text File Part ...This post continues from the first part. In this example the directory has a space in it so […] February 27, 2017 in SQL Server tagged export / file / sql / table by Mike
SQL Server Exporting a Table to a Text FileThis post describes how to export a SQL Server table to a text file using a stored procedure. […] February 27, 2017 in SQL Server tagged sql / bcp / xp_cmdshell by Mike
SQL Server char and varchar Data TypesCHAR is a fixed-length, non-Unicode string data. n defines the string length and must be a non-fractional value […] February 24, 2017 in SQL Server tagged sql / T-SQL / strings / char / varchar by Mike
SQL Server right() function with cast()The right() function returns the right part of a character string with the specified number of characters. It […] February 23, 2017 in SQL Server tagged right / sql / cast by Mike
SQL Server UNION and UNION ALLThe UNION, EXCEPT and INTERSECT operators are relational operators that combine rows from the results sets of two […] February 23, 2017 in SQL Server tagged sql by Mike
SQL Server Date Conversion FunctionHere we have a couple of code examples that work with dates. The first one gets today’s date […] February 7, 2017 in SQL Server tagged function / sql / date / Julian by Mike
SQL Server Finding Bad CharactersIn SQL Server you can run a SELECT query that shows you all of the records that have […] February 7, 2017 in SQL Server tagged sql / data validation / like / collate by Mike
SQL Server T-SQL StatementsAs mentioned earlier, the Transact-SQL statements have three categories: DDL statements, DCL statements, and DML statements. Each of […] February 5, 2017 in SQL Server tagged sql / DML / DDL / DCL by Mike