February 2010
1 post
Feb 10th
18 notes
January 2010
4 posts
Extremely high volume of whales
twitterstatus: We are experiencing an outage due to an extremely high number of whales.  Our on-call team is working on a fix. its not like twitter actually does anything else; where is the scaling issue coming from at this point?
Jan 20th
52 notes
Gaps
One feature I wish SQL Management Studio had is Paste and increment number. I frequently have to populate tables of lists with a integer reference code. If i have a code string of: Insert into MyTable Select 1, ‘EN’, … It would be great if i could paste in the value and have it change the 1 to a 2.
Jan 20th
1 note
Changing SQL Server collation without DTS
If you find yourself needing to change collation on databases when you restore them; you can DTS the data but that is fraught with risk. the fantastic script here http://www.db-staff.com/index.php/microsoft-sql-server/69-change-collation can do it in one pass without changing the objects in the  database :)
Jan 14th
1 note
Lonely Planet iPhone Content List 12/1/10
Taken from the Buy Guides feature of the Lonely Planet iPhone application; as there doesn’t seem to be a list anywhere else. The application came with Mexican Phrasebook and San Francisco City Guide pre installed. Amsterdam City Guide Arabic Phrasebook Auckland City Guide Bangkok City Guide Barcelona City Guide Beijing City Guide Belfast City Guide Berlin City Guide Boston City...
Jan 12th
December 2009
3 posts
Regex - Simple Example for wildcard users
I can’t sit down and write regex; as i use it so infrequently. SQL Management studio’s support for wildcards provides support for most things I need. Sourcesafe doesn’t have that same search facility and required me to use regex. Figured that text*text was a standard thing to use it for; only couldn’t find any examples on the web. What i came up with was Text.*Text
Dec 31st
Windows XP / Remote Desktop Connection Woes
“Unable to log you in because of an account restriction” This means you need to set a password on the Account and by default Windows XP requires one for remote desktop connections. Set a password and all should be well.
Dec 29th
Enable xp_cmdshell in SQl 2008
If you need to call xp_cmdshell you need to allow it; this script enables it. EXEC sp_configure ‘show advanced options’, 1 GO RECONFIGURE GO EXEC sp_configure ‘xp_cmdshell’, 1 GO RECONFIGURE GO
Dec 18th
1 note
November 2009
4 posts
Terminal Services Licensing Work Around
Found myself dialing onto a terminal server for admin that i rarely use this morning; only to get the dreaded your license to use this has expired message. If you want to clear that you need to delete a registry key. The Key is HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSLicensing\ Delete that whole key including all subfolders. When you go back into terminal services client it is recreated. If you...
Nov 26th
SQL 2008 Upload Files from Folder into Table
In the dark days there was a simple exe for uploading files into a database; that has gone. Found myself working on a data import and need to upload my files into blob;s openquery is my friend. You need to enable cmd shell or find another way of getting the file names into SQL Server but this will let you pick up all the files in a folder in one hit. Its quick too 10k RTF / Word Files on my test...
Nov 22nd
Remove a user from All Databases
When i restore a database i often have to remove users out as they don’t exist on the SQL Server. This script deletes all occurrences of a username in all databases on a server. sp_msforeachdb ‘use [?]; drop user yourusername’
Nov 22nd
Quick Repository for SQL Scripts
I don’t have a blog; and keep writing scripts i think others might find useful; so now i do…
Nov 22nd