Viewing 15 posts - 31 through 45 (of 64 total)
Here is a Trigger that I created and currently use on SQL 2005 and 2008.
It monitors when someone creates a new DB and emails me the information, including the create...
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 13, 2011 at 1:46 pm
First create the user in the database, the issue this statement.
Make them members of database role 'db_datareader'
and grant them access to create views and SP.
They will not have access to...
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 13, 2011 at 1:22 pm
In SQL 2008 You have now Auditing.
Create a Database Specific Audit on [msdb] and track this.
[Audit Action Type] = Execute
[Object Name] = [dbo].[sp_delete_job]; [dbo].[sp_delete_jobstep]; [dbo].[sp_delete_jobsteplog]
[Principal Name] = [public]
This will catch...
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 13, 2011 at 1:11 pm
Create linked servers to each of your instances and run the following code on them:
Here is the Status column description:
1 = autoclose; set with ALTER DATABASE.
4...
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 13, 2011 at 12:27 pm
You don't need to make it that complicated.
Just use this:
Now.ToString("yyyyMmdd_HHmmss")
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 13, 2011 at 12:06 pm
you can run this query and filter on the job_id
SELECT * FROM dbo.sysjobsteps
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 13, 2011 at 11:52 am
Antivirus is probably blocking you from sending emails.
Talk to your Security Admin and Exchange Admin.
If you have setup the Mail Client correctly, then you are probably being blocked by Exchange,...
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 13, 2011 at 11:45 am
The is no one single way of determining when SSIS will perform better than a Stored Procedure.
But you must take this into cosideration:
1) When you make operational changes within a...
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 13, 2011 at 11:39 am
You should try to use an AD account at all cost.
I find it more secure because it's password policies are managed by AD.
Try not to use "sa" on any connection...
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 13, 2011 at 11:20 am
This script should work just fine:
You may want to modify it a little so it first checks if the user exists:
drop Login [login_name]
go
sp_msforeachDB 'Use [?]; DROP USER [user_name];'
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 12, 2011 at 7:29 pm
Yes this is completely possible on SQL 2005 and newer:
To limit visibility to database metadata, execute this code DENY VIEW ANY DATABASE TO [MySQLLogingUser]. After this permission is denied, a...
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 12, 2011 at 7:24 pm
Use this code:
SELECT l.name as grantee_name, p.state_desc, p.permission_name
FROM sys.server_permissions AS p JOIN sys.server_principals AS l
ON p.grantee_principal_id = l.principal_id
WHERE permission_name = 'VIEW ANY DEFINITION' ;
GO
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 12, 2011 at 7:20 pm
GRANT VIEW DEFINITION
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 12, 2011 at 7:13 pm
A DBA Should be local admin because of the many administrative tasks that need to be performed on the Server itself.
A DBA needs to be able to:
Secure the Windows Server
Configure...
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 12, 2011 at 6:54 pm
Yes,
Every time that SQL registers an error with the with severity 22, which is a fatal error, then the alert is fired.
In order for you recieve and email when that...
Ysaias Portes | Forward Thinkers Consulting
sp_SQLFlightRecorder — open-source SQL Server diagnostic recorder | forwardthinkersconsulting.com
April 12, 2011 at 6:45 pm
Viewing 15 posts - 31 through 45 (of 64 total)