Viewing 15 posts - 61 through 75 (of 455 total)
or this;
select profile_id, name from [msdb].[dbo].[sysmail_profile]
/*
update [msdb].[dbo].[sysmail_principalprofile]
set is_default = 1
where profile_id = --Enter the profile_id number you want to make default
*/
June 8, 2012 at 12:14 pm
like this. (uncomment the --exec (@deletecmd) )
USE AT YOUR OWN RISK!!!
create table ##table ([DB_Name] varchar(128) DEFAULT NULL,[Name] varchar(100), [Type] char(1), Default_Schema_Name varchar(128), Type_Desc varchar(128))
declare @DB_name nvarchar(250)
declare db_crsr_DBS cursor for
select name...
June 8, 2012 at 11:57 am
here is your select command from the above script;
select 'USE ['+[DB_Name]+']; DROP USER ['+[Name]+'];' from @table
June 8, 2012 at 11:23 am
try something like this to populate a table variable that you can use to create your PRINT command for execution.
declare @table table ([DB_Name] varchar(128) DEFAULT NULL,[Name] varchar(100), [Type] char(1), Default_Schema_Name...
June 8, 2012 at 11:14 am
yep, your script will delete users but only if they do not own any schemas.
your script will fail if it finds 'USER1' and 'USER1' owned a schema. This happens when...
June 8, 2012 at 5:46 am
this would be possible, however, it gets complicated if you are doing it on a SQL 2005+ server.
if the user owns a schema, you can't drop it until the schema...
June 7, 2012 at 7:39 am
charipg (6/6/2012)
is DBCC CHECKDB REPAIR_REBUILD works for this issue ?
i wouldn't do that in PROD. you could run that command in a lower enviroment and TEST, TEST, TEST.
June 6, 2012 at 7:58 am
you also never set @x or @z to start you while loop.
June 6, 2012 at 7:51 am
from a quick look, you are only trying to shrink databases that EQUAL 8500.
maybe you meant > 8500
June 6, 2012 at 7:48 am
I'm really curious as to HOW a dbcc checkdb runs cleans whilst a select query returns the I/O error...
if that is possible, then how would one know when the last...
June 6, 2012 at 7:20 am
SQL does this by design because reading memory is faster than reading from disk.
the bigger concern would be not HOW much memory is being used, but how WELL is the...
June 6, 2012 at 6:59 am
Hi Kim,
thanks for sharing. i would have to agree that this info you are after is easily gathered from the SQL Server Logs.
Also, you can get what you are after...
June 6, 2012 at 6:26 am
June 5, 2012 at 11:54 am
i think you mean the column in which you choose to partition by.
in partitioning, you choose a column in which to define the partition range. so if you have a...
June 5, 2012 at 11:50 am
Viewing 15 posts - 61 through 75 (of 455 total)