About John Sansom

I’m a Microsoft Certified Master(MCM) of SQL Server. I’ve been working with database technology in a variety of flavors for over fifteen years. I absolutely love what I do and genuinely feel privileged to be a part of our tremendous technology community. Got a question about SQL Server or being a DBA? Ask me!


  1. I never knew that we could calculate the memory utilization of each DB!!! It was very helpful. Thanks.

  2. it was good.
    it help me lot………..

  3. Quick and nice way of getting memory usage, this query certainly works on both SQL 2005 and 2008…

  4. Vaishu105 says:

    hii can u please tell me the query to find the db size.. :) 

    • There are quite a few different ways you can achieve this. If you just want to look at the overall database size you can use the system stored procedure sp_helpdb. If you want to look at the size of each database data/log file individually then you can run the following query from Pinal Dave’s blog I hope this helps.

  5. Hey Great article, is this page count in MB or kilobytes? thanks

  6. HI John,

    I stumbled upon your website via Kevin Kline’s web site. I really enjoyed your website and what you have posted. It is very didactic and fun as well. One of the blogs that I like is the “Over-confidence” blog when you ran the query to create a Subscriber on a Publication….then it created locking…. I was thinking that if this happened to me, I would probably peed on my pants!-:)
    Great blog!

    Best of luck,

    • Daniel – delighted you discovered the blog sir! No one is perfect, which is why I try to share posts that are authentic as well as helpful. The time you describe was certainly a nerve wracking moment for me but thankfully pee free. It’s experiences such as this when a Data Professional really earns their keep, as well as provide opportunities for reflection and growth. Certainly helps to keep things interesting ;-)

      Thanks for your comments.

Leave a comment