Oh dude, digital storage. I am somewhere around »external #18« by now.
But I am SO happy to be using MacOS and being able to swap stuff around quickly.
Someone needs a drobo
Oh dude, digital storage. I am somewhere around »external #18« by now.
But I am SO happy to be using MacOS and being able to swap stuff around quickly.
Someone needs a drobo
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?
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.
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 :)
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.
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
“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.
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
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 find that when you run the terminal services client again, the registry key isn’t re-created. To have it re-created, run mstsc.exe as Administrator.
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 server took about 2 minutes.
go
drop table dbo.FilesInFolder
drop table myTable2
Create Table dbo.FilesInFolder(myFileName nvarchar(255))
Create TABLE myTable2(Document image, myFileName nvarchar(255))
Insert into FilesInFolder
exec master..xp_cmdshell ‘for %a in (C:\Users\Administrator\Desktop\F01\*.*) do @echo %a’
exec master..xp_cmdshell ‘for %a in (C:\Users\Administrator\Desktop\Excel\*.*) do @echo %a’
Alter table FilesInFolder add FileNumber int identity(1,1)
Declare @i int, @maxi int, @FileName nvarchar(1000), @mYSQL nvarchar(4000)
Select @i = 1, @maxi = COUNT(*) from FilesInFolder where not myFileName is null
While @i <= @maxi
Begin
select @FileName = myfilename from FilesInFolder where filenumber = @i
select @mYSQL = ‘INSERT INTO myTable2(Document, myfilename) SELECT *, ”’ + REPLACE(@FileName,’C:\Users\Administrator\Desktop\F01',”) + ”’ FROM OPENROWSET(BULK N”’ + @FileName + ”’, SINGLE_BLOB) as i’
exec sp_executesql @mYSQL
select @i = @i + 1
End