June 2017
M T W T F S S
« May    
 1234
567891011
12131415161718
19202122232425
2627282930  

Archives

Meta

Recent Posts

Tags

asp .net asp .net membership browsers computer crash Guy Burstein javascript link-o-rama LINQ office 2007 optimization outlook 2007 performance ScottGu SQL Server t-sql web servers workarounds xmlhttprequest

SQL: Updating One Table with the Values of Another Table

Thursday, March 4th, 2010

For one reason or another, I often have to update rows in one table with the values in another table, and every time I do, I end up Googling for the answer.
I don’t claim to have come up with this little code snippet* but I’m putting it up here so I don’t have to waste [...]

SQL Server 2005’s Pivot…PIVOT, PIVVOOOOT – Ross Gellar, Friends

Friday, May 9th, 2008

Every time I see SQL Server’s 2005 PIVOT, I think of that episode of Friends where Ross tries to guide his friends as they bring up the couch to his apartment.

But serious, PIVOT is one of those things that I’m still trying to wrap my brain around.
I’m currently digesting this: Pivots with Dynamic Columns in [...]

SQL Server: Data types text / ntext won’t play with sort or LIKE.

Tuesday, April 22nd, 2008

Msg 306, Level 16, State 2, Line 1
The text, ntext, and image data types cannot be compared or sorted, except when using IS NULL or LIKE operator.
Pretty self-explanatory.
In order to compare or sort text/ntext, you need to convert it to varchar (or similar datatype that can allow compare/sort). Note, text/ntext often has a large capacity [...]