Skip to main content

Posts

Performance Dashboard

SQL Server 2008 provide graphical reports for monitoring system health and performance. While there have always been various queries, stored procedures,  Dynamic Management Views, to gather system statistics, none were graphical. These new reports provide a quick easy way to print off a professional looking report for presentations or discussions.  This is an additional add-on feature of  SQL Server Management Studio which is also known as Performance Dashboard . We Can Start Report from Below : When select Stand Reports, below built in reports will be displayed. Disk Usage by Top Tables Disk Usage by Table Disk Usage by Partition Backup and Restore Events All Transactions All Blocking Transactions Top Transactions by Age Top Transactions by Blocked Transactions Count Top Transactions by Locks Count Resource Locking Statistics by Objects Object Execute Statistics Database Consistency history Inde

3 Easy Steps to Configure Database Mail

Database Mail is an enterprise solution for sending e-mail messages from the SQL Server Database Engine.  I am going to use Database Mail to Configure Automation Failure Notification.. Create an e-mail profile, specify its SMTP accounts and  Specify profile security. Configure Operator. Assign Operator on Jobs/Schedulers. In First Step: Create an e-mail profile, specify its SMTP accounts. To Varify check TSQL   use msdb SELECT *   FROM [msdb] . [dbo] . [sysmail_profile] Now Enable Database Mail service. USE master Go EXEC sp_configure 'show advanced options' , 1 Go RECONFIGURE Go EXEC sp_configure 'Database Mail XPs' , 1 Go RECONFIGURE Go EXEC sp_configure 'show advanced options' , 0 Go RECONFIGURE Go In 2nd Step : Configure Operator. To Varify TSQL   use msdb SELECT *    FROM [msdb] . [dbo] . [sysoper

Searching Hard Coded Values

Searching Hard Coded Values from Entire Database-Objects is very Interesting Task for me. My last Blog ( Search Dynamic Values ) was for Dynamic Values from Tables . Today I want to show how I am searching Hard Coded values (E-mail Ids and Mobile numbers) from all  Procedures  or  Views  from our Database.We should avoid the Hard codes in objects. To manages Hard codes in objects  i was simply Converting all procedures and Views in script and after that using find -replace i was managing changes...It was very time consuming and bothering work form me... Below Query help and save my lot of time for learning extras..... declare @text varchar ( 100 ) declare @dbname varchar ( 100 )        set @text = 'sumank'   set @dbname = 'masterdatabase' if @dbname is null begin --enumerate all databases. DECLARE #db CURSOR FOR Select Name from master .. sysdatabases declare @c_dbname varchar ( 64 )    OPEN #db FETCH #d

Searching from Entire Database

Searching from ENTIRE DATABASE is the common requirement for every dba/developer in organization. My boss is always asking to me Suman Check this 958200000  MOBILE NUMBER or smnjha989@gmail.com   E-ID where is available and replace with this new number, he/she left the Position but still getting notification in mail or alert in mobile…  It was very time consuming task for me … But Now this is easy for me for finding. Just running the below query and after few minute gives the table name-column name and value where it contains………….. I am using below TSQL just try……….. DECLARE @SearchingText nvarchar ( 256 ) SET   @SearchingText = 'XXXXXXXXXXXXX' BEGIN       CREATE TABLE #Results ( ColumnName nvarchar ( 370 ), ColumnValue nvarchar ( 3630 ))       SET NOCOUNT ON       DECLARE @TableName nvarchar ( 256 ), @ColumnName nvarchar ( 128 ), @SearchStr2 nvarchar ( 110 )       SET   @TableName = ''       SET @SearchStr2 = QUOTE

What is DBMS & RDBMS

DBMS Database Management System is defined as the software program that is used to manage all the databases that are stored on the network or system hard disk. The database system in which the relationships among different tables are maintained is called Relational Database Management System. Both RDBMS and DBMS are used to store information in physical database. RDBMS solution is required when large amounts of data are to be stored as well as maintained. A relational data model consists of indexes, keys, foreign keys, tables and their relationships with other tables. Relational DBMS enforces the rules even though foreign keys are support by both RDBMS and DBMS.