Viewing 15 posts - 2,866 through 2,880 (of 13,469 total)
you have to make sure ALL of your variables are the same (nvarchar(max))
Truncation when concatenating depends on datatype.
if you do something like this:
nvarchar(max) + varchar(n)
SQL will first convert the...
November 27, 2013 at 6:48 am
mailtoashokberwal (11/27/2013)
I need to compare two strings which have comma separated ISO Country codes.
For example : String1 = '356,840'
...
November 27, 2013 at 6:37 am
if not too much time has passed, it will be in the default trace;
but the default trace only keeps a rolling history of 100 meg, so it could get pushed...
November 26, 2013 at 2:59 pm
ok, flexing my Google-Fu a little bit, i found this article that might help; it claims to find long running jobs in 2000-2008 versions:
http://archive.msdn.microsoft.com/SQLExamples/Wiki/View.aspx?title=AgentLongRunning
November 26, 2013 at 1:51 pm
lptech (11/26/2013)
Start with the sysjobactivity table, and you should be able to come up with something that fits your needs.
I don't have a 2000 server to test agaisnt, but assuming...
November 26, 2013 at 1:22 pm
hunchback (11/26/2013)
WHERE ...
...
November 26, 2013 at 9:20 am
ok, a kewl sneaky way taking advantage of parsename
Declare @TableName varchar(128) ='ABCD_kkk_DDD'
SELECT PARSENAME(REPLACE(@TableName,'_','.'),2)
and the long drawn out way:
Declare @TableName varchar(128) ='ABCD_kkk_DDD'
SELECT SUBSTRING(@TableName,0,CHARINDEX('_',@TableName)) As Pt1,
REPLACE(@TableName,SUBSTRING(@TableName,0,CHARINDEX('_',@TableName))+'_','') As Inprogress,
SUBSTRING(REPLACE(@TableName,SUBSTRING(@TableName,0,CHARINDEX('_',@TableName))+'_',''),0,CHARINDEX('_',REPLACE(@TableName,SUBSTRING(@TableName,0,CHARINDEX('_',@TableName))+'_','')))
As Part2
November 26, 2013 at 7:25 am
there's nothing wrong with receiving that warning; some of the data you are looking at is null, and that's normal; some data has never been updated, only origianlly inserted is...
November 26, 2013 at 6:34 am
as far as i know, if you try to run chkdsk on a disk that is active in any way, it will tell you it cannot do it.
if it was...
November 26, 2013 at 6:21 am
test for the data with an exists:
IF EXISTS( SELECT 1 from test1 WHERE sl_code=@cd AND DATEDIFF(DAY,doc_dt,GETDATE())=0) )
BEGIN
DECLARE @htmlbody VARCHAR(4000)
SET @htmlbody = 'This is a Simple Email...
November 26, 2013 at 6:04 am
vignesh.ms (11/26/2013)
I need to ensure some naming standards to users while creating tables.
All table name should be in same pattern
(ie., ) TeamName_EmpId_tablename
I need a way to restrict...
November 26, 2013 at 5:59 am
sorry, no loop required;
you need to create a semicolon delimited list of the files, including the full path.
this worked for me:
CREATE TABLE #files(File_Name varchar(200), depth int, fil int)
INSERT #files
EXEC master.dbo.xp_dirtree...
November 25, 2013 at 2:31 pm
i see how to show/hide columns based on wether they are exported or not here:
but i don't see how to filter based on the export type yet.
November 25, 2013 at 2:23 pm
Skypass (11/25/2013)
How do I attach all files in a network folder to an e-mail (without zipping) using sp_send_dbmail.
The names and number of files in the folder will keep changing. ...
November 25, 2013 at 2:02 pm
this link will probably help enourmously, and keep you from granting sysadmin rights when it's not required:
Microsoft.com:Configure a User to Create and Manage SQL Server Agent Jobs
November 25, 2013 at 1:52 pm
Viewing 15 posts - 2,866 through 2,880 (of 13,469 total)