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

Daily Coping Tip

Find three good reasons to be hopeful for the future

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.

Licensing Audit Advice

I've never been through  a licensing audit, but I have been worried about them a few times in my career. While I've tried to ensure that the organizations I worked for were compliant, I've always worried about losing track, making a mistake, or mis-interpreting the EULA rules. Those are not written for most people to understand, and the verbiage is ambiguous at times.

I saw an article containing advice on going through a licensing audit that caught my eye. This was for an Oracle audit, but I suspect the advice would be similar if this were for SQL Server or any other product. Since this is a legal proceeding, it's worth treating any licensing audit as you would a legal matter.

I am not a lawyer, and don't take this to be advice or a recommendation. For me, I would try to go slow with everything. Not to delay, but to be careful and sure of what I was doing. Concentrate and read all documents carefully, being sure that I know what they mean, asking for clarification if there is any doubt, and ensuring my organization's legal representative was available for questions.

I'd especially be careful about only answering questions and not being overly talkative and volunteering information. I've seen plenty of people get into trouble because they talk more than necessary. That might be good advice for life in general: listen more; talk less.

SQL Server, unlike many products, can be tricky because no license key is really checked. I've seen scripting and manual processes use the same product key for ever installation. There's nothing fundamentally wrong with this, but it does mean that someone is still responsible for ensuring that licenses are being tracked against installations and upgrades.

While I have no desire to deal with licensing, I know that if I act as a DBA in any way, it's likely part of my job. I would (and have) tried to get someone in an Accounting role to keep track of purchases and usage of licensing, updating them whenever I install or decommission an instance. At least then we have more than one person tracking the data and potentially another person that might be in charge of handling the audit ;).

Steve Jones - SSC Editor

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

 
  Featured Contents
Stairway to Machine Learning Services

What is the Machine Learning Server? Level 2 of the Stairway to ML Services

ginger.grant from SQLServerCentral.com

In Level 2, we look at the architecture and structure of the Machine Learning Services server process.

SQL Server Business Continuity – Know Your Options

Additional Articles from MSSQLTips.com

SQL Server database business continuity, including high availability and disaster recovery, is not an easy topic to engineer for. The business must work with the IT teams to define service-level agreements, statistically significant scenarios to plan for, and then decide on a budget.

Automate Oracle database deployments with Redgate Change Automation

Additional Articles from Redgate

We’re excited to introduce a brand-new capability of the Deployment Suite for Oracle: Redgate Change Automation is a command line tool with built-in safety checks that lets you safely automate your Oracle database deployment. With four commands that help you build, test, prepare, and perform Oracle database releases, Redgate Change Automation can be used as part of a CI/CD pipeline.

Free eBook: SQL Server Internals: In-Memory OLTP

Press Release from Redgate

In this free eBook, Kalen Delaney explains how Microsoft's 2016 In-memory OLTP engine works. In her book, learn how to use lock- and latch-free data structures to allow non-blocking data processing, and find out how to migrate existing tables to Hekaton.

From the SQL Server Central Blogs - Step-by-Step: iSCSI Target Server Cluster in Azure

david.bermingham from Clustering for Mere Mortals

I recently helped someone build an iSCSI target server cluster in Azure and realized that I never wrote a step-by-step guide for that particular configuration. So to remedy that,...

From the SQL Server Central Blogs - Refresh databases that belongs to Availability Group using dbatools

Cláudio Silva from Cláudio Silva

Few days ago I was surfing on Twitter when dbatools asked about how it’s PowerShell module changed the way people work. We're looking to highlight how dbatools has changed...

 

  Question of the Day

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

 

Getting the Mean

I have this dataframe in Python:
sales.head()
	Date	Day	Month	Year	Customer_Age	Age_Group	Customer_Gender	Country	State	Product_Category	Sub_Category	Product	Order_Quantity	Unit_Cost	Unit_Price	Profit	Cost	Revenue
0	2013-11-26	26	November	2013	19	Youth (<25)	M	Canada	British Columbia	Accessories	Bike Racks	Hitch Rack - 4-Bike	8	45	120	590	360	950
1	2015-11-26	26	November	2015	19	Youth (<25)	M	Canada	British Columbia	Accessories	Bike Racks	Hitch Rack - 4-Bike	8	45	120	590	360	950
2	2014-03-23	23	March	2014	49	Adults (35-64)	M	Australia	New South Wales	Accessories	Bike Racks	Hitch Rack - 4-Bike	23	45	120	1366	1035	2401
3	2016-03-23	23	March	2016	49	Adults (35-64)	M	Australia	New South Wales	Accessories	Bike Racks	Hitch Rack - 4-Bike	20	45	120	1188	900	2088
4	2014-05-15	15	May	2014	47	Adults (35-64)	F	Australia	New South Wales	Accessories	Bike Racks	Hitch Rack - 4-Bike	4	45	120	238	180	418
Which of these will give me the mean of the profit column?

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)

Clearing Database Cache

I have a SQL Server 2019 instance and I want to clear the procedure cache, but only for the plans used by one database, Sales. How should I do this?

Answer: ALTER DATABASE SCOPED CONFIGURATION CLEAR PROCEDURE_CACHE

Explanation: To clear the cache for just a single database, use the ALTER DATABASE SCOPED CONFIGURATION command. Ref: ALTER DATABASE COPED COFIGURATION - https://docs.microsoft.com/en-us/sql/t-sql/statements/alter-database-scoped-configuration-transact-sql?view=sql-server-ver15

Discuss this question and answer on the forums

 

Featured Script

Getting more info about who or what connect to your SQL Server

FlamesNAshes from SQLServerCentral

A couple of days ago I was playing with my small SQL Server enviroment (test) and auditting login events. I went ahead and created the audit for FAILED_LOGIN_GROUP and SUCCESSFULL_LOGIN_GROUP (let it run for a while). USE [master] GO CREATE SERVER AUDIT [Audit_LoginEvents] TO FILE ( FILEPATH = N'' ,MAXSIZE = 100 MB ,MAX_FILES = […]

 

More »

 

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
SQL Server 2017 Availability Groups - I could really use some sage words of wisdom from the SQL Server Central community on Availability Groups in SQL Server 2017. I’ve wanted to implement AG for a while now but a coming increase of 200x our current work and going to 24x7 operation with no maintenance window has pretty much forced them into […]
SQL Server 2017 - Development
one Rows in two Line in Result one line in one row - Hello, i have often the Problem that i must the information from 2 line (1 row) i need in 1 line Example: Select car,model,engine,details from cars ( |= stands for row) Honda| Civic| 1.6| deluxe Honda| Civic| 1.6| basic VW| Golf| 1.5| basic VW| Golf| 1.5| extra Dodge| Viper| 8.4| performance Dodge| Viper| 8.4| last_edition […]
SQL Server 2016 - Administration
Collation Error: 468 when trying to view login properties in SSMS - Hello experts, I was recently confronted with a dev SQL Server that had been installed with the SQL_Latin1_General_CP1_CI_AS when it requires SQL_Latin1_General_CP1_CS_AS. I tried the steps at the following link, which looks like they rebuilt the system and user databases using SQL_Latin1_General_CP1_CI_AS. Change SQL Server Collation – Back to Basics The recommended command was (using […]
How to display non-English characters in SSMS ? - I have a table that contains English and non-English entries, particularly Russian. The column is defined as nvarchar. If I BCP it out and open in notepad, it clearly displays  Russian characters. But not in SSMS. Is there any setting for this? My SSMS version is 13.0.16106.4. Thanks  
Is AG listener name being used in the apps...how to capture on the SQL side? - Due to the hurricane season around we have a requirement to have all the applications point out to using the AG listener name. However, we would like to identify if there are any connections that are coming through and hitting the actual SQL instance name instead of using the AG listener name...this would help us […]
SQL Server 2016 - Development and T-SQL
Merge not updating in explicit transaction - We have the following code in a stored procedure which has a merge statement and an update statement to a different table in an explicit transaction. The merge update does not update any data in the inventory.gtin table but the update statement below it works and data is updated in the import.file_data table when the […]
SQL 2012 - General
SQL 2012 Always-On issues? - Hey Eveyrone! We have a 2012R2 Always-On setup for our application.  It does get very busy more so at the end of month, however, just recently, about 2 weeks ago a lot of our clients are getting timeouts when connecting to our web app.  The application admin is blaming Always-On but after reviewing the wait […]
SQL Server 2012 - T-SQL
Filtering out based Start Date and End Date - Hello, I have query contains both start and end date, i would like to filter out data based on two dates. I need only 2019 and higher data either based on start or end date, if you can have a look examples. i need ID 1,2,3,6,7 and 4,5 is  not required. I have tried using […]
SQL Server 2019 - Administration
moving one 500 GB DB from lower version to SQL Server 2019 - Hello Gurus, Task is to move a  500 GB  DB from lower version ( source ) to a brand new server ( destination- SQL Server 2019 ) . Plan is to use logshipping. Take a full backup on Source , restore full backup  on Destination with Standby / ReadOnly . Tlog backups will automatically be […]
SQL Server 2019 - Development
Week Ending Thursday, can some one tweek my code? - What I have missed from this code? I'm trying to show the DateTimeRaised field as a week ending Sunday and week ending Thursday. The FkIssueGroupID isn't unique but each row should have the same date. The MAX is being used to bring back a single row. Whilst the week ending value for Thursday is correct […]
Find Space occupied by a Row - Hi All, Do we have any way to find out the space occupied by individual records in a table? My objective is to find out the space occupied by each record in a table where columns names can vary from int, float, varchar, nvarchar(max) etc. For example, in below table, where content of both the […]
Invalid length parameter passed to the LEFT or SUBSTRING function. - HI, I am using the below query to fetch a data from SQL server. But the query returned Invalid length parameter passed to the LEFT or SUBSTRING function. error. Any help in solving the issue would be much appreciated.  TIA. SUBSTRING(output_response_xml, LEN(LEFT(output_response_xml, CHARINDEX ('>Thank you', output_response_xml))) + 1, LEN(output_response_xml) - LEN(LEFT(output_response_xml, CHARINDEX ('>Thank you', output_response_xml))) […]
syntax error on insert - Hi, I am brand new to SQL.  I'm using postgres with PopSQL interface. I am trying to run the following basic code from a tutorial but it gives me a Failed Error: syntax error at or near "INSERT"   Here is the code: CREATE TABLE people ( id INT, name VARCHAR(255), PRIMARY KEY(id) ) INSERT INTO people VALUES (1, 'Corey');
Reporting Services
AccessibleTablix - I am following this article to turn on  AccessibleTablix=true in  RsReportServer.config  in SSRS 2017, but cannot find the tag. Section 508 and SSRS Help please
COVID-19 Pandemic
Daily Coping 29 May 2020 - Today’s tip is today link your decisions and choices to your purpose in life. Daily Coping 29 May 2020
 

 

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

 

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