Displaying posts published in

May 2013

XML Data in where clause

XML Data in where clause XML Data in Document Types. Step1 : Create Table XMLData. Step2 : Insert XML Document Types Data. Step3 : Where clause for XML Data Type. XML Data in Element Types. Step1 : Truncate XML Data table and insert some element type XML data in the same table. Step2 : Where [...]

SQL Server connection in WMI Script

SQL Server connection in WMI Script. VB Script provides composition of WMI and SQL Server. You can connect SQL Server and store WMI informations in SQL Server. Before reading this blog you already know that WMI is also works like central communication machine for all network servers. To know more read http://nirav.extreme-advice.com/2013/05/15/get-disk-space-usage-from-central-server-with-wmi/. I have created one [...]

Monitor performance counter with WMI and SQL Server

Monitor performance counter with WMI and SQL Server. WMI is very important to use as central monitoring task. I have created performance monitoring which checks Disk Queue Legth, Disk Read/Sec, Disk Write/Sec, CPU Usage, Memory Usage, Disk Read Bytes/Sec, Disk Write Bytes/Sec, ASP Request/Sec. Create a table “PerformanceCounter” to store all information. Open Notepad and save [...]

Change file location of Master Database

Change file location of Master Database. To change file location of other database is very easy and it can be done in three steps. Step1 Detach that database. Step2 Cut from Old location and paste mdf and ldf files to new location. Step3 Attach database with new location. To change file location of master database [...]

Get List of Stopped SQL Services from central server with WMI

Get List of Stopped SQL Services from central server with WMI. As a DBA we have to monitor many things. To monitor all SQL Server Serives wotking properly works fine we have to check status of services periodically. We can do that it manually or automatically, Manually – By using Services.msc, Automatically – By using [...]

Get Disk space usage from central server with WMI

Get Disk space usage from central server with WMI. As a DBA job we have to check server health regularly. sometime that happens when you are working on multiple servers and its very difficult to monitor health of all servers. I faced the same issue last week. My application abnormally going down and i am [...]

Log Shipping with SQL Server 2012

Log Shipping with SQL Server 2012. SQL Server provides many ways for disaster recovery and log shipping is one of them. You can configure log shipping in three topology. 1). Configure log shipping on one instance with different database name. 2). Configure log shipping on different instance in same server. 3). Configure log shipping on [...]

Schedule SSIS Package Without Deploying

Schedule SSIS Package Without Deploying. You can schedule your package before you completely deploy it. you just need to build your SSIS Package and you will get executable “.dtsx” file. Path for “.dtsx” file is different according to SQL Server versions. For SQL Serve 2008 :  “your package path \bin\*.dtsx” For SQL Serve 2012 :  “your [...]