Category Archives: Best Practices

How to backup SQL table ?

Backup SQL table, have you ever tried to backup a single SQL table inside a database? Let’s see How to backup SQL table | SQL Table Backup Restore DOES SQL Server supports table level backups ? Backup Types are dependent on SQL Server Recovery Model. Every recovery model lets you back up whole or partial [...]

50 Database Optimization TIPS

Database Optimization TIPS helps any system to perform work efficiently and quickly. SQL Server Performance tuning is very wide subject and there are a lot of different pieces to troubleshoot a poor performing application. Connectivity / Network Server Hardware Operating System SQL Server Database Query The basic principle of Optimization / Tuning is Profile First [...]

SHRINK LOG File SQL

SQL Server Database Log File has grown exponentially over a period of time and now causing DISK space issue, how to reduce | Shrink Log file SQL Database (.ldf) size? Steps to truncating log files and shrinking your database Get logical / physical name of your database log file (LDF) Truncate LOG File Shrink LOG [...]

Strategy to Improve SQL Server Performance

What Steps / Strategy we should opt to Improve SQL Server Performance ? Increasing SQL Server Performance being expected by every DBA. Performance can not be increased just by running perfmon , task manager or running profile. We should have straight forward steps to increase SQL Server Performance. The Steps to Improve SQL Server Performance [...]

How to check Database Statistics are optimized for Performance ?

What is Statistics in SQL Server ? Statistics helps Query Optimizer to makes a decision to choose the fast good (best) way to execute a given query. Statistics decides, whether to choose  a particular index or not and build the execution plan. So if your stats are not updated then Optimizer might not choose the [...]

Optimization Tips

Database Scheme Optimization Tips Devote the appropriate resources to schema design. Separate online analytical processing (OLAP) and online transaction processing (OLTP) workloads. Normalize first, denormalize later for performance. Define all primary keys and foreign key relationships. Define all unique constraints and check constraints. Choose the most appropriate data type. Use indexed views for denormalization. Partition [...]

Querying Data in SQL Server Part 2

Calculating column values If you want to do calculations on a column like add, subtract, multiply, modulus or division. You can use the arithmetic operators like (+, -, /, *, %). Now in our table TABLE1 we have one column STDID containing integer values & I want to add all the values by 20. The [...]