A peer the other day was having some trouble storing some some Chinese characters in a database. Every time he would insert the data into his table, the results would look similar to the following. The phrase he was adding was similar to the following: 烟肉独角兽彩虹乳酪 The T-SQL he was using was forwarded to me … Continue reading The Power of N
Category: T-SQL
ABCs of CTEs at PASSMN
Last week I presented at the March Minnesota SQL Server User Group (PASSMN) meeting on using CTEs in SQL Server. The session is meant as an overview and introduction to CTEs with some examples of their use and what some of the effects can be. Overall the session was well received and I got the … Continue reading ABCs of CTEs at PASSMN
SSWUG Spring ’10 Ultimate Virtual Conference
The SSWUG Spring 2010 Virtual Conference is coming up. On April 7, 8, and 9, attend a conference from the comforts of your living room, office, or couch. And while you are at it you’ll get to sit on on some incredible presentations, interaction with speakers, chat with other attendees, make new contacts, lots of … Continue reading SSWUG Spring ’10 Ultimate Virtual Conference
Find Tables with Forwarded Records
A while ago I had read about the hidden threat of forwarded records. These silent killers are like storm troopers in the bush waiting to get you when you least expect it. And then the other day I saw a T-SQL Tuesday post by Sankar Reddy on (blog – twitter) on determining if your SQL … Continue reading Find Tables with Forwarded Records
Grouping and Rounding Dates
Ever need to group dates and round them to intervals? I had this exact need for a report on wait stats I was working on for an upcoming post. I wanted the flexibility to be able to group a list of dates by either minute, hour, date, etc. And then also round those dates within … Continue reading Grouping and Rounding Dates
Please, no TRIM()?
A couple weeks back I was asked “How come Microsoft has yet to put TRIM() in SQL?” I don’t really know why there isn’t a TRIM() function in SQL Server. There is an LTRIM for function removing leading spaces. And an RTRIM function for removing trailing spaces. But there isn’t a TRIM function. Let’s be … Continue reading Please, no TRIM()?
SQL Saturday 32 — ABCs of CTEs Deck
I’d like to thank Pam Shaw (twitter as @pamshaw) and Jorge Nunez (twitter as @sqlchicken) for letting me come down to Tampa this past weekend to present at SQL Saturday #32. Jeez, that picture doesn’t make me look very happy. For someone like me that tends to forget to take time off, this is a … Continue reading SQL Saturday 32 — ABCs of CTEs Deck
Speaking at Tampa SQL Saturday
I've been selected to speak at the Tampa SQL Saturday coming up at the end of January. I'm a bit pumped to be going down there since I woke up this morning to below zero weather for yet another day. Not that I'm complaining, but my feet could definitely use a little bit of heat. … Continue reading Speaking at Tampa SQL Saturday
Does Your Stored Procedure Grant Itself Permissions?
It’s a very good question. One that might not seem to insidious. Nothing that should be able to bring down the system and cause failures. Or will it? I’ve been to a number of clients and done it myself before where I start to check out a stored procedure with some performance issues and sitting … Continue reading Does Your Stored Procedure Grant Itself Permissions?
Checking EXISTS – What’s Your Practice?
Michael Swart (Database Whisperer) posted a great write up and interview with Brad Schulz that is worth checking out. Michael’s post links to a post from Brad on the use of EXIST and what is required for the SELECT portion of the statement. Hope you are still with me. Definitely worth the read and +1 … Continue reading Checking EXISTS – What’s Your Practice?