Tag Archives: code language
-
SQL Homework – December 2020 – Participate in the Advent of Code.
Leave a commentDecember 3, 2020 by Kenneth Fisher
Christmas. Depending on where you live it’s a big deal even if you aren’t Christian. It pervades almost every aspect …
Continue reading -
Generate a random number of children for each parent
4October 3, 2018 by Kenneth Fisher
I was asked an interesting question the other day. Is it possible to get a different random number of rows …
Continue reading -
Escaping strings
Leave a commentSeptember 24, 2018 by Kenneth Fisher
No, I’m not talking about that nightmare everyone has where a bunch of strings are chasing you across a loom. …
Continue reading -
Using Table Valued Parameters with sp_executesql
3September 13, 2018 by Kenneth Fisher
Recently I did a presentation on dynamic SQL. In the presentation I pointed out the similarity of using sp_executesql to …
Continue reading -
SQL Puzzle: Advent of Code
Leave a commentAugust 29, 2018 by Kenneth Fisher
A few years back someone started the Advent of code. If you aren’t familiar with it, it’s an advent calendar …
Continue reading -
Moving a table using BCP and native format
7March 21, 2018 by Kenneth Fisher
You need to move a table from one instance to another with the following requirements: The instances are on separate …
Continue reading -
Working with “special” names
4October 19, 2015 by Kenneth Fisher
What do you do when you need to use a special character in a name? Well, I guess I should …
Continue reading -
Updating a view
2September 30, 2015 by Kenneth Fisher
I was recently asked how to update views. Specifically the question was about using triggers to update a view. So …
Continue reading -
“sql_handle” is not a recognized table hints option.
Leave a commentSeptember 23, 2015 by Kenneth Fisher
I’ve you’ve run a query similar to the following: And gotten an error similar to: Msg 321, Level 15, State …
Continue reading