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

Daily Coping Tip

Focus on the basics: eat well, exercise, and go to bed on time

I also have a thread at SQLServerCentral dealing with coping mechanisms and resources. Feel free to participate.

For many of you out there working in a new way, I'm including a thought of the day on how to cope in this challenging time from The Action for Happiness Coping Calendar. My items will be on my blog, feel free to share yours.

The Real Life Software Movie Plot

It wasn't that long ago that Firewall was released. In it, a security executive has his family taken hostage, with the plot being that the executive will help the criminals rob the bank that he's spent years protecting or his family will be killed.

While I haven't heard of this extreme happening in the real world, I wonder how far away we are from this. Recently, there was a less violent attempt at hacking, with someone offering a Tesla employee over US$1mm to slip ransomware into their network. The idea would have been to threaten Tesla with data release unless they paid up. The details are interesting, and supposedly the ransomware cost US$250,000 to build, but another company paid US$4.5mm to criminals, so maybe this would have been very profitable.

I'm sure there have been some shady offline attacks against companies and their executives or privileged staff. I hope there haven't been any violent ones, but I am sure that something has happened somewhere in the world.

Ultimately, I bet that the best defense might be to limit the knowledge of who can access sensitive data, and perhaps even ensure that no one can. Only systems, and that all queries, all access, and certainly all backups, are handled by some automated system, logging everything. This might not prevent this movie plot from coming true, but maybe you'd get a similar ending, with the criminals caught quickly because some system logged the action and alerted people.

Security is a tough world to work in and think about constantly. Many of us know this, dealing with the stress and concern on a regular basis. Hopefully none of us add in the moral dilemma that might come from an actual criminal contacting us. If they did, hopefully all of us would be able to do the right thing.

Steve Jones - SSC Editor

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

 
 Featured Contents

SCOM Alert: MSSQL 2014: SQL Server cannot authenticate using Kerberos

iLearnSQL from SQLServerCentral

Learn how to correct an error that is overloading SCOM by fixing an SPN.

The Two Ways Containers Will Revolutionize Database DevOps

Additional Articles from SimpleTalk

Containers have already transformed the way application development works, but adoption has been slower for databases. Finally, the revolution is beginning. In this post, Kendra Little shares the two ways in which containers will dramatically change the way teams develop and deploy database changes.

From the SQL Server Central Blogs - Adaptive Joins in SQL Server

SQLEspresso from SQLEspresso

SQL Server 2017 (compatibility 140) brought us many Intelligent Query Processing (IQP), formally known as Adaptive Query Processing, features that improve performance on workloads straight out of the box...

From the SQL Server Central Blogs - Skip Validation of SSIS Packages

Koen Verbeeck from Koen Verbeeck

There’s been an update of the SSIS extension for Visual Studio 2019. There are some bug fixes and deployments are blocked to Azure-SSIS if the target server version is...

 

 Question of the Day

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

 

The New Database Owner

I create a new login in SQL Server 2019, without any roles. I then grant this login the CREATE ANY DATABASE permission. When this login creates a database, who is the database owner?

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)

The pyodbc Connection from Python

I import the pyodbc module into my Python environment. I want to use the connect() method to access data in SQL Server. What parameters are needed?

Answer: Just a connection string

Explanation: The connection string is the main parameter needed. Ref: pyodbc module - https://github.com/mkleehammer/pyodbc/wiki/The-pyodbc-Module

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
Always OnAavailability Group Read Traffic - Does anyone know of any good references on how to direct application reads and SSRS reads between the primary and read-only replicas? I would like to have all application reads go to the primary and not the read-only replica.
SQL Server 2016 - Administration
Retrieving the total number of records in a SQL instance - Hello, Is anyone aware of a good approach for retrieving the total number of records across all tables and all databases within a SQL instance?  I've attempted to write a query for it, but it isn't working as expected. SET NOCOUNT ON DECLARE @Counter INT, @MaxId INT, @DbName VARCHAR(100), @Sql VARCHAR(100) SELECT @Counter = min(database_id) […]
Monitoring SQL Server performance. SQL Server, Disks baselining - Hey everyone, hope you all are doing great. I got a couple of questions regarding OS/SQL Server information capture and its regarding how you guys capture data and baseline everything in your SQL Server/OS Performance. Here it goes, this might not make perfect sense at the beginning so I hope you guys could cut some […]
SQL Server 2016 - Development and T-SQL
Complex Join - I have to tables T1 and T2 that are related by two columns C1 and C2.  Both columns are null-able so it's not as simple as: T1 join T2 on T1.C1 = T2.C1 and T1.C2 = T2.C2 So I've come up with this: T1 join T2 on ( T2.C1 = T1.C1 and T1.C2 is null […]
Administration - SQL Server 2014
Distribution DB increasing in size - We have a transaction replication running. We then decided that on a certain application, they would enable a module that would increase data in one of the tables. Prior to this, the Distribution was only 10GB, after 3 days, it is now 27 GB and constantly increasing. I see on the autogrow event that it […]
SQL 2012 - General
High parallel processes - Hi, I have a SQL server 2012 instance (Ver-11.0.5058). We execute a stored procedure which fetches more than 24 million records after joining data from 3 different CTEs (each of which has 3 to 7 tables in join). The MAXDOP for the instance is set to 8 and server has 16 logical processors. When we […]
Break AOAG - Hello, I'm looking for advice on breaking a 2 node cluster / AOAG down to a stand-alone instance, the catch being without changing the way the applications connect. There are about 8 different SW Dev. apps that have DBs on this instance. I was thinking of creating a DNS record with the listeners name and […]
SQL Server 2019 - Development
Silly SQL Question - I'm sure there's a simple way to do this, but I can't seem to figure it out.  I have data something like this: ID, RESULT 1, Y 1, Y 1, Y 2, N 2, N 3, Y 3, N 4, Y 4, N I only want to pull records where the ID has both a […]
Issues with SQL Trigger - I have created a SQL Trigger as below. create trigger testtrigger on testdb for insert as declare @sql varchar(8000) SELECT @sql = 'bcp "select * from testdb" queryout c:/test.txt -c -t -T -S localhost' exec xp_cmdshell @sql go But when a row inserted in the testdb, the text file is created, but there is no […]
Reporting Services
Access to Field!xxxx.value - I have not come across where I needed to do this, I have a report that uses multiple datsets, " I have done this before, but I need to take the value from one dataset field and subtract it from another, as you know when you bind the table to ds1 you get scope errors, […]
SSRS 2017 Delivery Extension Deployment - In SSRS 2008 to 2012 the code block for permissions in rssrvpolicy.config is below. Does anyone know what code block is used in SSRS 2017?
Connecting
Connecting to SQL server 2019 from python/Jupyter Notebooks - Does anybody have an example of connecting to a local instance of SQL Server from Jupyter notebooks? Do I really have to create a DSN to do this? ## define some variables so this stuff is easier to modify server = 'DESKTOP-D19S9C8/NONALAND' database_name = 'AdventureWorks2017' query = 'SELECT TOP 10 BusinessEntityID,FirstName,LastName,ModifiedDate FROM Person.Person WHERE PersonType […]
Powershell
How to check if the file exists in S3 bucket. - Hi, I am trying to build a script to copy sql backups to an S3 bucket.  The structure of the folders is like this: ServerName - FullBackups -- Daily -- Weekly -- Monthly Inside the lower level folders are the backups.  But the structure may change.  I have a script below which recursively looks through […]
Suggestions
Spam removal from https://www.sqlservercentral.com/forums/ page - Firstly I like the fact that as soon as a post is marked as spam it's hidden. Perhaps they could be hidden from the https://www.sqlservercentral.com/forums/ overview page as well?
Business Intelligence
Job fails with error : Failed to add row to output buffer SSIS - I have a data flow task with 2 components : source ODBC : with more than 3 000 000 rows OLEDB Destination : it's my table destination . the job works perfectly every day at 2:00 AM . But this day it fails with the folowing error  message : The system reports 97 percent memory. […]
 

 

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

 

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