Viewing 15 posts - 49,126 through 49,140 (of 49,571 total)
Many ways, but it depends greatly on what the root problem is.
Have a look in the performance forum, iirc there are a few posts on getting started with monitoring...
May 18, 2006 at 2:54 am
However, if you're still using SQL 2000, then the max datatypes are not available (New feature in 2005) and you're stuck with TEXT for large text strings.
May 17, 2006 at 7:54 am
The error has more to do with the wierd way text fields behave than anything wrong with your parameters. You might have some success using READTEXT, but I don't really...
May 17, 2006 at 2:30 am
What you're trying to do can't be done in SQL 2000 (function in FROM with parameter been a field from the query). It's a new feature in SQL 2005 (CROSS...
May 17, 2006 at 2:24 am
In theory
CREATE PROCEDURE TestOutput (
@InputParameter INT
@OutputParameter INT OUTPUT
)
AS
.....
DECLARE @Result INT
EXEC TestOutput @InputParameter = 1, @OutputParameter = @Result OUTPUT
Note the OUTPUT keyword, both when creating the stored proc and wne...
May 17, 2006 at 2:00 am
and statistics cannot be mintained on them, so the optimiser has little to no idea how many rows are in the table variable when it generates a query plan.
May 12, 2006 at 3:31 am
If you are going to be doing this kind of query, create a linked server and map the windows authenticated logins on one to a sql authenticated login on the...
May 11, 2006 at 3:42 am
Cursors, especially nested cursors are not going to work very well, ever. I suggest a set-based solution.
This isn't a complete solution, but should give you a good idea where to...
May 11, 2006 at 2:55 am
IF EXISTS(SELECT 1 FROM mytable)
RAISERROR (...)
No need for variables or anything.
May 10, 2006 at 12:35 am
I usually use this when I'm optimising queries.
set
statistics io on
set statistics time on
May 4, 2006 at 5:53 am
From books online
status | int | Status bits for the growth value in either megabytes (MB) or kilobytes (KB). 0x2 = Disk file. 0x40 = Log file. 0x100000 = Growth. This... |
May 2, 2006 at 4:17 am
I tend to use this one. Not sure if it's the best, but it is way better than the usual cast as varchar version. Haven't seen any strange issues
SELECT CAST(FLOOR(CAST(GETDATE()...
April 28, 2006 at 12:08 am
What does this return?
DECLARE @val VARCHAR(50)
SELECT name from dbo.sysobjects where OBJECTPROPERTY(id, N'IsConstraint') = 1 AND name like 'PK__TestTable%'
select @val = name from dbo.sysobjects where OBJECTPROPERTY(id, N'IsConstraint') = 1 AND name...
April 21, 2006 at 3:56 am
If you print the string instead of executing it, what does it contain?
April 21, 2006 at 3:28 am
You'll need to use dynamic SQL in this case, as an alter table can't take a variable.
DECLARE @val VARCHAR(50)
select @val = name from dbo.sysobjects where OBJECTPROPERTY(id, N'IsConstraint') = 1 AND...
April 21, 2006 at 1:51 am
Viewing 15 posts - 49,126 through 49,140 (of 49,571 total)