June 2025 Discount: Comprehensive Database Performance Health Check | Testimonials

Home
  • Consulting
  • Training
  • Free Videos
  • All Articles
    • Interview Questions and Answers
    • SQL Tips and Tricks
    • SQL Performance
    • SQL Puzzle
    • Big Data
    • Blog Stats
    • SQL Books
    • Search SQLAuthority
  • Downloads
  • Hire Me
  • Health Check

SQL SERVER – Adding Datetime and Time Values Using Variables

October 30, 2015
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
SQL DateTime
Datetime datatype stores date and time part. If you have only date value, You can add time part to a datetime variable using direct literal value and + operator. It is shown below DECLARE @date DATETIME SET @date='2010-10-01' SET @date=@date+'15:00:00' SELECT @date AS DATETIME The result is 2010-10-01 15:00:00.000 But…
Read More

SQL SERVER – Who is consuming CPU on my SQL Server?

October 29, 2015
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
SQL CPU
The topics around performance tuning is always interesting and I get quizzed by a number of you during conferences on these topic areas post my presentation. A relatively simple yet a powerful question was asked by one of the attendee in my session at MODS (Mobile Developer Conference) this year.…
Read More

SQL SERVER – What is Semantics Search Inside SQL Server?

October 28, 2015
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
Every now and then I bump into stuffs that I didn’t even hear about when it comes to working with SQL Server. This time I heard the word Semantics Search and was wondering where and when did it come. In this blog, I will put the foundation for this and…
Read More

SQL SERVER – Script level upgrade for database ‘master’ failed – CREATE SCHEMA failed due to previous errors

October 27, 2015
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
SQL Error Messages
SQL Server troubleshooting topics seem to be the most searched for in this blog. In continuation to this, blog for today is also inspired with one such error message. Some time back I have written below blog which talks about upgrade script mode of SQL Server: SQL SERVER – Login…
Read More

SQL SERVER – Taking Backup Without Consuming Disk Space

October 26, 2015
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
SQL Backup and Restore
Long back, I learned this trick and found an interesting use of it. I totally understand that its very dangerous. Recently I have seen someone getting bitten by this so thought of sharing. Warning: Don’t do this in any production environment The trick here is to take backup on NUL…
Read More

Interview Question of the Week #042 – How Does SPACE Function Works in SQL Server?

October 25, 2015
Pinal Dave
SQL, SQL Interview Questions and Answers, SQL Server, SQL Tips and Tricks
This question may sound strange but I have personally observed this being asked in one of the interview. Question: How Does SPACE Function Works in SQL Server? Answer: SPACE function accepts one numeric parameter and generates as many as space as a value of the parameter. Observe the output of the…
Read More

SQL SERVER – Simple Way to Find Existence of Column in a Table

October 24, 2015
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
If you want to check if the column is already available in the table, you can use system views like sys.columns or INFORMATION_SCHEMA.COLUMNS. Let us create this dataset USE TEMPDB; CREATE TABLE TESTING(ID INT, NAME VARCHAR(100)) Suppose you want to find out the existence of the column named NAME and…
Read More

SQL SERVER – How to Identify InMemory Objects Can be Identified in SQL Server?

October 23, 2015
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
In-Memory OLTP
When SQL Server introduced InMemory OLTP functionality, it is a great addition to the database. I have seen people use this capability in limited capacity for specific use case scenarios. As a seasoned developer, it is difficult to know what are the consumers of memory. In a recent conversation, I…
Read More

SQL SERVER – Interesting Observations Using MONEY Datatype

October 22, 2015
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
SQL Datatype, SQL PASS
MONEY is one of the data types supported in SQL Server. There are some interesting information about this. Observation 1: Money datatype can accept up to four scale values. DECLARE @money money SET @money='$1,200.45679' SELECT @money which results to 1200.4567 Observation 2: If the scales value exceeds 4 digits, it is rounded to…
Read More

SQL SERVER – Database Size Limitation in SQL Express

October 21, 2015
Pinal Dave
SQL, SQL Server, SQL Tips and Tricks
SQL Server Express
I have a tendency to write a number of interview style questions and those are quite popular in this blog. Having said that, sometimes we get asked about tricky questions on a small variety which we might know some of the basics – but sometimes it makes us think twice.…
Read More
Previous 1 … 233 234 235 236 237 238 239 … 579 Next
  • SQL Interview Q & A
  • Testimonials
  • Search
  • Privacy Policy

© 2006 – 2025 All rights reserved. pinal @ SQLAuthority.com