Problems displaying this newsletter? View online.
SQL Server Central
Featured Contents
Question of the Day
The Voice of the DBA
 

SQL Is Always Going to be Popular

Hiring staff is hard, and certainly it can sometimes be a challenge to find good people to build software and manage systems. Many of us want to be those good people, and we are looking to improve our own skills. I think that's one of the reasons that SQLServerCentral has become so popular. Many of us want to become better at our jobs.

It can be hard to determine what to learn and where to invest your time. I've talked with plenty of people that have worried about various Microsoft technologies and their longevity. Notification Services is the classic example, but I know people that have been wary of SSIS, Power BI, Azure, and more. It's daunting to consider spending 100 hours across the next year on some technology, only to find it's not likely to help you get the job you want.

Recently there was an analysis of the coding tests that were given to developers by various companies. This is interesting to look at from an employee view, when thinking what skills to work on. One thing I see is that SQL is constantly in demand. It ranks on the second most test language, only behind Javascript. That makes sense in that lots of companies need help with web technologies, and there are lots of these jobs.

What I'd also say is that most every job out there needs SQL. Whether you are a web developer, a mobile or client side developer, you use Java, Python, C#, or anything else, you'll work with a database. Even many of the NoSQL class of databases have added SQL as a query language for developers.

SQL, for all of its shortcomings, is a standard way of working with data. It's a skill that isn't likely to go away anytime soon and the more you can build efficient queries, the more likely it is that you'll impress someone in the next interview. Read our T-SQL articles and practice answering questions in the forums, and you might be surprised at how much of a T-SQL guru you can become.

Steve Jones - SSC Editor

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

Redgate SQL Compare
 
 Featured Contents
Stairway to Exploring Database Metadata

SQL Server Extended Properties: Stairway to Exploring Database Metadata Level 7

Phil Factor from SQLServerCentral.com

In this level, I’ll introduce Extended Properties. As with the previous levels, I want to illustrate as much as possible with practical and immediately useful code.

Never Create Columns with ANSI_PADDING set to OFF

Site Owners from SQLServerCentral

There is no good reason for having ANSI_PADDING set to OFF when you create tables in SQL Server. It was provided purely for legacy databases that had code that assumed the old CHAR behavior for dealing with padding, and its use has now been deprecated.

Securely Manage Database Credentials Using Visual Studio Manage User Secrets

Additional Articles from MSSQLTips.com

In this tip we cover how to manage application secrets in a development environment to securely store database credentials.

Free eBook: SQL Server Execution Plans, Third Edition

Press Release from Redgate

If a query is performing poorly, and you can't understand why, then that query's execution plan will tell you not only what data set is coming back, but also what SQL Server did, and in what order, to get that data. It will reveal how the data was retrieved, and from which tables and indexes, what types of joins were used, at what point filtering, sorting and aggregation occurred, and a whole lot more. These details will often highlight the likely source of any problem.

From the SQL Server Central Blogs - T-SQL Tuesday #124 – Monitoring Query Store’s Impact on Your System

taboggiano@gmail.com from Database Superhero’s Blog

This month’s T-SQL Tuesday blogging party is brought to you well by me and I wanted to talk more about Query Store.  I did write a book on it...

From the SQL Server Central Blogs - Telecommute Resources

Diligentdba 46159 from Mala's Data Blog

This is a summary of potential resources for any tech person who is interested in working from home – temporarily or full time. It came about from a twitter...

 

 Question of the Day

Today's question (by Steve Jones - SSC Editor):

 

Filtering Data

I have a simple data frame that looks like this:
> passing.2019
     Player Yards Conf age
1   Winston  5109  NFC  26
2  Prescott  4902  NFC  25
3      Goff  4638  NFC  26
4    Rivers  4615  AFC  38
5      Ryan  4466  NFC  34
6    Wilson  4110  NFC  31
7     Brady  4057  AFC  42
8      carr  4054  AFC  28
9     Wentz  4039  NFC  27
10  Mahomes  4031  AFC  24
I want to reduce this down to those players in the AFC that are older than 30. Which of these functions will do this?

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

 

 

 Yesterday's Question of the Day (by Steve Jones - SSC Editor)

Get a couple fruits

I have this code:

DECLARE @s VARCHAR(500) = 'apple,pear,banana,peach,orange,strawberry,blueberry,lime'

SELECT TOP 2 *
 FROM STRING_SPLIT(@s, ',') AS ss

What is returned from this?

Answer: could be any 2 of the fruits from the string

Explanation: As with many SELECT statements, the output from STRING_SPLIT() is not guaranteed to be in the same order as the source string. In practice, this almost always returns apple and pear, but you should not count on this. Ref: string_split() - https://docs.microsoft.com/en-us/sql/t-sql/functions/string-split-transact-sql?view=sql-server-ver15

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 - Administration
Missing dumps during unexpected server reboot - One of my critical database server had an unexpected reboot followed by server hung issue but sadly we are unable to find any related errors in the event logs or SQL logs . Also there was no dumps generated . I recollect there is a way that the dumps can be generated later as well […]
SQL Server 2016 - Administration
Finding databases with no dependencies - Hello experts, This is more of a conceptual question - I'm pretty sure I can do all of the legwork once I get pointed in the right direction. How does one go about finding which databases on a server have no dependencies? I realize this may not be totally possible because some developer might have […]
Weird issue with data transfer to Oracle - Hello all...  had an odd issue crop up and was wondering if anyone had ideas on what might have caused it... We have a nightly job that copies data from one of our local databases (SQL Server 2016) to an Oracle database at our corporate headquarters.  The setup is pretty basic - we have a […]
SQL Server 2016 - Development and T-SQL
Procedure Error - has no parameters and arguments were supplied - DECLARE @FROMDATE SMALLDATETIME, @TODATE SMALLDATETIME, @SERVER_NAME NVARCHAR(150) SELECT a.ServerName,a.DatabaseName,a.DatabaseSize,b.DatabaseSize,a.TrackDate as Todate_Size,a.TotalSize,b.TrackDate as FromDate_Size ,b.TotalSize, (a.TotalSize-b.TotalSize) AS GrowthSizeDiff FROM (SELECT ServerName, DatabaseName , DatabaseSize , LogSize , TotalSize , TrackDate =(CONVERT (DATE, TrackDate, 103)) FROM Database_Size_Tracking WHERE servername = @SERVER_NAME AND (CONVERT (DATE, TrackDate, 103)) =(CONVERT (DATE, @TODATE, 103))) A, (SELECT ServerName, DatabaseName , DatabaseSize , […]
count(*) locking a table? - Hello, Why would select count(*) from a table encounter a lock? The table in question had initial bulk insert (append records) and then update happens on those new records. In the meantime I queried the total rows - count(*) and it locked the whole thing. Eventually I had to kill the query with count(*). Did […]
Administration - SQL Server 2014
SQL Server CPU utilization - Hi there, i am using this script to get the cpu utilization. Unfortanetly I get wrong results. The NonSQLCPUUtilization is always negative. It's a SQL Server 2014 with CU4. We have an other SQL Server 2014 with CU4 where it works correctly. Any hints are appreciated. Regards select top 10 id, SQLServerCPUUtilization, 100 - SystemIdle […]
Configuring SQL Replication using Remote Distributor: Create Publication Error - Dear Team, I am currently on SQL server 2014 R2 and I have been trying to replicate my LIVE database to a report server using a remote Distributor. Currently, i am getting the error as shown below: TITLE: New Publication Wizard ------------------------------ SQL Server could not create publication 'XXDB_PUB'. ------------------------------ ADDITIONAL INFORMATION: An exception occurred […]
Encrypted Log Shipping - I've found a number of articles on encrypting backups and transaction log backups, but all these are based on manually generated code to include the encryption details in the backup command. Is there anything out there covering how Log Shipping can be enabled to include encryption, and if so what version of SQL has this […]
SQL 2012 - General
Fulltext: modify system stoplist - Hello there, I have a customer that wishes to remove a stop word from the fulltext stoplist. Unfortunately, currently we are only using the system stoplist. Yes, I know I can create a custom stoplist, rebind it to the indexes etc. A colleaghue came with the idea of just deleting the word from the sys.fulltext_system_stopwords. […]
String extraction - SQL 2012 - Hi, I need to make changes to the below to only extract '2002' as the result. select REPLACE(REPLACE(SUBSTRING('CKnovelty2002_pouch-5AR-OneSize',1,CHARINDEX('-','CKnovelty2002_pouch-5AR-OneSize',1) - 1),'CKnovelty',''),'CKflower','') At the moment, I am getting '2002_pouch' as the result which is incorrect. The expected output is '2002'. Can somebody please help in this regard ? Many thanks.          
SQL Server 2019 - Administration
Need replacement for Microsoft RDCManager - which is being deprecated March 2020 - Due to vulnerability, Microsoft is deprecating RDCMan (LINK listed below) Does anyone have a recommendation on a replacement RDCMan?  I have over 200 SQL Servers (VM's & Physcial's) that I connect to... and I have them neatly defined in RDCManager by PROD, STAGE, TEST, DEV and by Application System. Looking for a replacement for RDCMan […]
SQL Server 2019 - Development
top cqu sql how to tune - there is a function in legacy code  view below and the ind query shows up as top sql. Any idea how to remove the function and replace it with adhoc sql. Individual t-sql SELECT @Type = coalesce(@Type + ', ', '') + type_desc from _dataDictionary_type where type_id IN (select type from _TYPE_MAPPING WITH (NOLOCK) where […]
SQL Server 2008 Performance Tuning
Optimise/ speedup query - Below query is used for inserting and updating the tables in the SQL Server database. The XQuery is slow while executing in SSMS for first time.I am using SQL Server 2008 R2. The total time taken for 500 queries is 20 to 40 seconds. How can I optimise this query to speed up the execution? […]
SSRS 2016
PowerBI Paginated Reports vs SSRS reports - I have a reportserver where I am currently deploying both PowerBI desktop reports, and SSRS rdl reports. We're setting up standards for the team for our PowerBI reporting to match up to our SSRS standards (logos/header/footer elements/color schemes/etc.). Searching online has led us to the conclusion that adding header/footer is best served by using PowerBI […]
Integration Services
extract all data with week - Good morning all I have a table that contains the history of a table over 1 year old he asked me to extract one file per week so we total I must have 54 files Who can help me with this need please
 

 

RSS FeedTwitter

This email has been sent to {email}. 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.
©2019 Redgate Software Ltd, Newnham House, Cambridge Business Park, Cambridge, CB4 0WZ, United Kingdom. All rights reserved.
webmaster@sqlservercentral.com

 

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -