SQLServerCentral - www.sqlservercentral.com

A community of more than 1,600,000 database professionals and growing

Featured Contents

The Voice of the DBA

Lack of Memory

I was reading Brent's look at "normal memory" for his SQL ConstantCare® clients. It's a look at some stats from quite a few servers that customers have set up and he is monitoring. Since most of us only have a limited set of instances to examine, it's nice to see what a wide variety of installs are using. Even though this doesn't necessarily mean we should change anything in our environment, it does help me to understand some general trends, and perhaps think about how to recommend settings for new installations.

When we build a server, we expect it to work a certain way. Over time, we are almost always adding data to the system, but often we don't add more RAM. This would be like buying a vehicle and loading it up with supplies you need for work. If the amount of supplies kept growing, would you keep piling them on or buy/rent/borrow a bigger vehicle? Some would, some wouldn't.  I'm always amazed by how far people will push a situation, especially when fairly small and inexpensive changes might make a big difference.

Data size isn't always a good indicator of how much memory you should allocate, but it can be. Certainly the more data we query in a workload, the more memory makes a difference. Bad code is more likely to surface issues, but memory is often cheaper than paying developers, or usually, finding and training developers to write better code. For a DBA, this might be one of the relatively few differences we can make in the short term that has a far reaching effect. Adding memory might cover up some poor coding and speed up the experience for clients in the short term. In the long term, things will likely tip over again.

If you manage an instance, you can't usually change code, and it can be hard to get developers to prioritize changing existing code. Most developers are pressured to move forward with new work, not refactor old work. One of the reasons I like moving clients to a database DevOps flow is that DBAs with query tuning skills can spend more time tuning some queries and giving code to developers. It's much easier to get them to fix bad code if you give them better code than ask them to find time to rewrite things.

Getting the best performance out of your database server often a balancing act among various choices that each only solve a portion of the problem. Don't be hesitant about asking for more memory over time, but also be careful that you don't just depend on this one technique to reduce the number of customer complaints.

Steve Jones from SQLServerCentral.com

Join the debate, and respond to today's editorial on the forums


The Voice of the DBA Podcast

Listen to the MP3 Audio ( MB) podcast or subscribe to the feed at iTunes and Libsyn. feed

The Voice of the DBA podcast features music by Everyday Jones. No relation, but I stumbled on to them and really like the music.

ADVERTISEMENT
SQL Prompt

Write, format, analyze, and refactor SQL fast with SQL Prompt

Writing SQL is 50% faster with SQL Prompt. Your SQL code can be formatted just the way you like it, you can create and share snippets with your team, and with code analysis you get suggestions to improve your SQL as you type. Download your free trial

SQL Monitor

The 4 pillars of SQL Server Monitoring

5 SQL Server experts; Grant Fritchey, Rodney Landrum, Kathi Kellenberger, Phil Factor and Tony Davis, use their many years of experience working and maintaining data systems to explain the 4 key strategies required for a successful, estate-wide monitoring solution.  Download your free copy now

Featured Contents

 

Workplace Encounter: Effects of TLS 1.2

Kenneth Igiri from SQLServerCentral.com

In this article we share a recent experience we had with implementing TLS 1.2 ONLY support on our databases and particularly with respect to its effect on Transaction Log Shipping sessions. More »


 

Working with SQL Server Stored Procedures and .NET

Additional Articles from MSSQLTips.com

Learn how to build a simple .NET application that uses SQL Server stored procedures to retrieve and update data from a database. More »


 

SSRS Reporting Basics: When is SSRS the Right Tool?

Additional Articles from SimpleTalk

SSRS has undergone a number of changes over the past few versions. It remains a very popular reporting tool in companies large and small. In this article, Eugene Meidinger recounts the history of SSRS and explains when it’s the best tool to use. More »


 

From the SQLServerCentral Blogs - Forecasting Kyle Kuzma’s Field Goal Percentage (FG%)

MarlonRibunal from SQLServerCentral Blogs

More and more tools are becoming available for data analysts and data scientists. These tools provide convenience and lower the bar... More »


 

From the SQLServerCentral Blogs - File Maintenance – Cleaning Up Old Files

Jason Brimhall from SQLServerCentral Blogs

Using SSIS to Maintain the File System We have all run into a need or a desire to clean up old... More »

Question of the Day

Today's Question (by Steve Jones):

I declare a small Sequence object like this:

 CREATE SEQUENCE s MINVALUE 1; 

How do I get the next value from the sequence and assign it to the variable @i?

Think you know the answer? Click here, and find out if you are right.


We keep track of your score to give you bragging rights against your peers.
This question is worth 1 point in this category: Sequence Object.

We'd love to give you credit for your own question and answer.
To submit a QOTD, simply log in to the Contribution Center.

ADVERTISEMENT

Pro Power BI Desktop

This book shows how to deliver eye-catching Business Intelligence with Microsoft Power BI Desktop. You can now take data from virtually any source and use it to produce stunning dashboards and compelling reports that will seize your audience’s attention. Slice and dice the data with remarkable ease then add metrics and KPIs to project the insights that create your competitive advantage.

Yesterday's Question of the Day

Yesterday's Question (by Steve Jones):

I have this data frame in R that contains the top 10 home run hitters in baseball. I use the summary function to get this data:

 > summary(HR.hitters) rank players Hr yrs.played Min. : 1.00 Albert Pujols :1 Min. :586.0 Min. :17.00 1st Qu.: 3.25 Alex Rodriguez:1 1st Qu.:613.8 1st Qu.:21.25 Median : 5.50 Babe Ruth :1 Median :645.0 Median :22.00 Mean : 5.50 Barry Bonds :1 Mean :664.3 Mean :21.10 3rd Qu.: 7.75 Frank Robinson:1 3rd Qu.:709.5 3rd Qu.:22.00 Max. :10.00 Hank Aaron :1 Max. :762.0 Max. :23.00 (Other) :4 

I run this:

 mode(HR.hitters$Hr)

What is returned?

Answer: "numeric"

Explanation:

The mode() function actually returns information about data types in R.

Ref: mode() - click here


» Discuss this question and answer on the forums

Database Pros Who Need Your Help

Here's a few of the new posts today on the forums. To see more, visit the forums.

SQL Server 2017 : SQL Server 2017 - Development

Updating rows with same date and same id while loading next file(s) - could it be Merge statement? (i used it once in the past i think). - i have 2 FILES (.CSV). I am just dump loading the raw contents of each into  Table1 and Table2 staging table..  THen...

Is it possible to Filter out Columns in Select statement? - We can filter Rows with WHERE clauses and JOINS etc But is there an easy way to filter Columns I was wondering...


SQL Server 2016 : SQL Server 2016 - Administration

Auditing changes to Maintenance plan jobs - Hi All, Someone suggested me to create a new post for this issue and here I am :) The problem is...

SQL Server 2016 License to install SQL Server 2008 - Can SQL Server 2016 license be used to install SQL Server 2008? Editions are same.


SQL Server 2016 : SQL Server 2016 - Development and T-SQL

How can I combine the data from two flat file outputs from two different data flow tasks into one Flat file?? - Hi Team, Is there a way to combine data from two flat file destinations from two different data flow tasks into...

Problem with executing SSIS Container, when not executed as standalone - Ahoi, Short introduction: I had a procedure that truncated and inserted a view into a table. The procedure is part of the...


SQL Server 2014 : Development - SQL Server 2014

Query Performance - Hello All, Wish you a very happy new year 2019!! I had been asked to review performance of a procedure and I...

Going from datetimeoffset to datetime - Hi All, I'm hoping to get guidance on this. I'm working on modifying a query used to pull data in an...


SQL Server 2012 : SQL 2012 - General

How to change CDC Function fn_cdc_map_lsn_to_time(__$start_lsn) to return UTC Datetime - Is there any possibilities on change the Return Datetime of sys

steps for performance tuning of a sql server - Hi I just wanted steps /how to troubleshoot sql server from perfmonace point of view or which is particualr query...

Linked Server issue - Hi All, Thanks for your time to look into my question. I have a SQL Server 2012 Enterprise edition connecting to another...


SQL Server 2012 : SQL Server 2012 - T-SQL

Recursive Parent Child Same Table - Is there a best practices way to join a table to itself for a parent child relationship? We have 2 tables...

Execute Dynamic Stored procedure - Hello Experts!! Merry Xmas !!!! Can you please help me to write and execute a dynamic stored procedure ? I need to import...


SQL Server 2008 : SQL Server 2008 - General

Where did our 30GBs go? - We have a bunch (~130 DBs) of databases that have the exact same table structure. We had an operation run over...

How Check string of Boolean expression is return true or false - Hi Guys, I have a requirement in my project is how to check string of boolean expression is true or...


Reporting Services : Reporting Services

My stored procedure returns results but, the report returns nothing - I have added option(recompile) at the end of my stored procedure but, the report still doesn't r


Reporting Services : SSRS 2016

Expanding Columns in SSRS Report - Hey, I am having one requirement pertinent to expand and hide columns based on click of  plus sign in column header...


Data Warehousing : Integration Services

Date field value changing to Null after loading into dimension table - Hi All, I'm trying to investigate an issue where a date field, PolicyCancelDt, of type datetime from an extract table is changing...

Unable to create SSISDB -  I would like to create SSISDB but even with sa password I see the below error. I am not sure...


SQL Server 7,2000 : Administration

Auditing changes to Database Maintenance plans - Is there a way to log changes made to database maintenance plans and / or SQL Agent Jobs? I have a...

This email has been sent to newsletter@newslettercollector.com. To be removed from this list, please click here.
If you have any problems leaving the list, please contact the webmaster@sqlservercentral.com.
This newsletter was sent to you because you signed up at SQLServerCentral.com.
Feel free to forward this to any colleagues that you think might be interested.
If you have received this email from a colleague, you can register to receive it here.
This transmission is ©2018 Redgate Software Ltd, Newnham House, Cambridge Business Park, Cambridge, CB4 0WZ, United Kingdom. All rights reserved.
Contact: webmaster@sqlservercentral.com