Viewing 15 posts - 496 through 510 (of 598 total)
Take a look at the COALESCE and ISNULL functions
May 10, 2006 at 9:08 am
Well, to do what you want, this would work:
UPDATE MyTable
set Notes = REPLACE(Notes, '''', '''''')
But more importantly, tell us why / how your job is failing and we should...
May 9, 2006 at 5:19 pm
so are the differences from calculations or are there different entries for the two?
If they are calculations, your query would look something like:
select
AMOUNT AS REVENUE, --with appropriate calculations
AMOUNT AS COST...
May 9, 2006 at 5:07 pm
Locking:
Locking / contention should show up if you issue a sp_who2 command.
You might also want to consider using:
SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED
on any stored procs / sql statements as...
May 9, 2006 at 1:38 pm
More ideas thrown out...
Have you looked at locking / contention issues?
Are there loops in these procs that might be getting "stuck"?
Have you run a profiler trace to see what SQL is...
May 9, 2006 at 1:13 pm
Totally untested...
SELECT t1.*
FROM dbo.
t1
JOIN
( SELECT [fK_id_1], [fK_id_2], MAX([date]) MaxDate
FROM dbo.
WHERE [primary]='Y'
GROUP BY [fK_id_1], [fK_id_2] ...
May 9, 2006 at 1:07 pm
Hmm. I'd be interested to see your whole process. At minimum, your first part could be trimmed to:
'AA' + CAST(ORG AS Varchar(50)) + '00' + CAST(Acct_Nbr AS Varchar(50)) + CAST(Tran_Code...
May 9, 2006 at 10:40 am
Not just you, Chris. I had it somewhere in my head that it was something like that, too. I just couldn't remember the value (thought it was 70 or 80)...
May 9, 2006 at 10:02 am
From BOL:
The default is 0. If fillfactor is 100 or 0, the Database Engine creates indexes with leaf pages filled to capacity, but some space remains within the upper level...
May 9, 2006 at 9:36 am
CREATE PROCEDURE sp_CreateTextFile
As
Select
CAST('AA' AS Varchar(50)) + CAST(ORG AS Varchar(50)) + CAST('00' AS Varchar(50)) + CAST(Acct_Nbr AS Varchar(50)) + CAST(Tran_Code AS Varchar(50)) + CAST(Amount AS Varchar(50)) AS MyAACol,
case...
May 9, 2006 at 9:23 am
From BOL: When fillfactor is 0, DBCC DBREINDEX uses the original fillfactor specified when the index was created.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/tsqlref/ts_dbcc_94mw.asp
May 9, 2006 at 9:12 am
declare @TheMonth int
select @TheMonth = DATEPART(mm, getdate())
select
case len(@TheMonth)
when 1 then
'0' + cast(@TheMonth) as char(1))
else
cast(@TheMonth as char(2))
end as StrMonth
You could also roll the...
May 9, 2006 at 8:51 am
Check out this blog: http://spaces.msn.com/drsql/
(May 2nd entry) for a discussion on just this topic.
May 9, 2006 at 7:38 am
Have you checked the articles on this site? There's a bunch of them geared towrads new DBA's. There's even a newbie DBA forum with some very helpful topics:
http://www.sqlservercentral.com/forums/shwmessage.aspx?forumid=169&messageid=120660
Look through...
May 9, 2006 at 7:32 am
Also:
DBCC CHECKDB returns the following result set (message) when NO_INFOMSGS is specified:
The command(s) completed successfully.
and from Checktables:
Return Value
A StringCollection object value that...
May 9, 2006 at 7:27 am
Viewing 15 posts - 496 through 510 (of 598 total)