Viewing 15 posts - 841 through 855 (of 7,168 total)
Alan.B (8/20/2013)
opc.three (8/19/2013)
DECLARE @sql NVARCHAR(MAX) = N'';
SELECT @sql += 'EXEC LoadFile ' + QUOTENAME(FILENAME,...
August 20, 2013 at 6:44 pm
ScottPletcher (8/20/2013)
Erland Sommarskog (8/20/2013)
curious_sqldba (8/20/2013)
In sys.sysprocesses wait type is always 'SOS_SCHEDULER_YIELD' when my CTP is 5 and MAXDOP is 0, what do you want me to check in sys.dm_os_tasks ?
How...
August 20, 2013 at 1:49 pm
And for completeness here is your XML version that handles character entitization properly by using TYPE with FOR XML and the .value XQuery method:
USE YourDatabaseName
go
IF OBJECT_ID('dbo.newtable') IS NOT NULL
...
August 19, 2013 at 10:03 pm
Erland Sommarskog (8/19/2013)
opc.three (8/19/2013)
August 19, 2013 at 9:54 pm
Stefan_G (8/19/2013)
But my code is still more useful since it returns the sql directly as a string to the code 🙂
The attempt is warranted but using XML has its drawbacks....
August 19, 2013 at 8:36 am
Erland Sommarskog (8/19/2013)
opc.three (8/19/2013)
DECLARE @sql NVARCHAR(MAX) = N'';
SELECT @sql += 'EXEC LoadFile ' +...
August 19, 2013 at 7:29 am
Here is a non-cursor option, just for the sake of having an alternative to using a cursor:
DECLARE @sql NVARCHAR(MAX) = N'';
SELECT @sql += 'EXEC LoadFile ' + QUOTENAME(FILENAME, '''') +...
August 19, 2013 at 2:07 am
The Import and Export Wizard reachable via SSMS is quite handy to copy data to a test instance. In SSMS Object Explorer, right-click your source database, select Tasks, and choose...
August 19, 2013 at 1:38 am
In SQL 2008 and 2005 a simple SQLCLR function that leverages the TryParse method of the Int32 object is the most complete way to check for whether a string value...
August 19, 2013 at 1:33 am
NJ-DBA (8/18/2013)
You might be interested in this article I wrote a while back about automatic checking of backup and error log entries via PowerShell: http://www.sqlservercentral.com/articles/powershell/76561/
Nice use of PowerShell.
August 19, 2013 at 1:22 am
Something like this?
USE YourDatabaseName;
GO
CREATE TABLE newtable
(
softwaremanufacturer VARCHAR(100),
productname VARCHAR(100),
productversion VARCHAR(100),
a VARCHAR(100),
b VARCHAR(100),
c VARCHAR(100),
d VARCHAR(100)
);
GO
WITH cte
...
August 19, 2013 at 1:15 am
OnlyOneRJ (8/18/2013)
below will be tyhe step which will be done incase of deletion..
1) Restore Last Full Backup (Normal Backup)
2) Restore all Log Backup Copies after Full...
August 18, 2013 at 11:11 pm
Jeff Moden (8/16/2013)
SQLRNNR (8/16/2013)
Jeff Moden (8/16/2013)
Retrofit (wishful thinking).partition
Spot-on
Spotfire
August 16, 2013 at 3:52 pm
SQLRNNR (8/16/2013)
Jeff Moden (8/16/2013)
Retrofit (wishful thinking).partition
refactor
August 16, 2013 at 1:02 pm
jeanna_mcmahon (8/8/2013)
August 13, 2013 at 11:21 am
Viewing 15 posts - 841 through 855 (of 7,168 total)