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

Daily Coping Tip

Focus on what you can do rather than what you can’t

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.

Crazy Interview Questions

Redgate had a discussion recently among our developers about our interview process and questions. There has been a standard question asking candidates about 2D arrays, but as one developer pointed out, we don't use these in our code base. So, why do we ask candidates about this topic?

The developers came up with a different question, actually a series of questions that ask about a class and then how to test parts of this class. We mostly work in C# in a DevOps culture, so this seemed like a good idea. They proposed a scenario with a few questions and then asked current developers to solve the question and give feedback on the language, structure, and difficulty of the problem.

I followed the technical discussion lightly, as I am not concerned about how effective this particular question might be in evaluating a candidate. I was more interested in why people felt this series of questions would give them insight into how a candidate thinks and devises solutions. This isn't a test so much as a chance to decide if a person can fit into a team and accomplish work. We tend to work in teams, so while the ability to write code is important, it is more important to collaborate, share, and learn from others.

In the end, I hope that the interviewers don't view this as a pass-fail, but rather as a spectrum that represents the opportunities a candidate would provide to advance the products we build forward in a positive way. Does the candidate ask questions, do they see the upsides and downsides of potential solutions. and do they view the challenge as a way to learn and get better? If they misread the problem or make a mistake, do they admit it? Do they realize that they went too fast or were too nervous here? I have seen plenty of candidates make syntactical error in coding because they are nervous or under pressure.

In school, mistakes often result in poor marks. An incorrect answer and lower grade are the result of simple mistakes. In the real world, we are not as often evaluated in black and white terms. We used peer review, unit tests, and code analysis to catch simple mistakes. We grow and learn from these errors and improve over time. At least, that's what I would hope most developers, as well as Operations staff, should do. A logic error in a WHERE clause or an incorrect partition for an OVER() aggregate might cause some issues, but we don't fire employees for making these mistakes. Why would we disqualify a candidate for doing so in a pressure-packed, short interview?

I've used to give questions as a test, but over time I started to use them as a way to gain insight into how an individual fits in a team. I've added poorly phrased and incorrect questions to see if someone catches my error. I've asked about impossible situations or problems my team hasn't been able to solve, just to see how people react. I've learned to appreciate the Kobayashi Maru-type scenarios that test someone's ability to cope with difficulties.

I saw a question from Amazon's interview process (allegedly) recently that asked about solving a hanging cable problem. I've seen some of the "MtFuji">How do you move Mt Fuji" questions that Microsoft used to ask. I can appreciate the challenge of asking highly technical people to think algorithmic-ally about how to accomplish a task. I just don't know if those types of questions help us build better teams.

What types of questions do you think help decide if a developer, or a DBA, would be competent in your environment? Are there any crazy ones that you felt stressed you, were extremely difficult, or maybe didn't help you pick a good candidate? Or maybe you have thoughts on what might better help you decide to choose one candidate over another. Let us know what you think today.

Steve Jones - SSC Editor

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

 
 Featured Contents
SQLServerCentral Article

Who is the Best Batman in Power BI

Daniel Calbimonte from SQLServerCentral

Who is the best Batman? – A Power BI Analysis of data Introduction Who is the best Batman? We were drinking some cold beers with some friends when someone said that Pattinson was the best Batman. People started to discuss and after 2 hours, the police had to stop the fight. The discussion inspires me […]

External Article

Working with Firebase Version 9 Modular SDK and React Typescript

Additional Articles from SimpleTalk

Firebase is a SaaS platform that provides developers with many services to improve productivity and reduce build time. In this article, Goodness Woke demonstrates working with Firebase Version 9 and React Typescript.

External Article

Flyway How-tos: a User’s Perspective

Additional Articles from Redgate

Flyway provides a database-independent way for a team to track, manage and apply database changes, while maintaining strict control of database versions. It updates a database by running a series of versioned migration scripts, in order, and keeps track of all the changes in a special "schema history" table. It sounds simple, but it is easy to derail this team discipline if you don't find the right answers to the following questions…

From the SQL Server Central Blogs - Microsoft Graph API in Power Automate: Adding Guest Users to your Tenant

Devin Knight from Devin Knight

This is video three in a four-part series walking you through how to leverage the Microsoft Graph API within Power Automate. In this video, you

Blog Post

From the SQL Server Central Blogs - Database Design for Tracking Solar Production

Steve Jones - SSC Editor from The Voice of the DBA

We had a solar system installed at our house this year. I’m excited to see how this performs, as our estimates and research shows this ought to be a...

 

 Question of the Day

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

 

Exporting Masked Data

I have some data that is protected by a Dynamic Data Mask. If my user (Joe_User) queries this data, they see this: Result set with masking This user tries to execute this code from a command line:
sqlcmd -S Aristotle -U Joe_User -d ddmtest  -Q "select ProductName, UnitPrice from orderdetail where orderid = 4" -o order4.txt
What will they see in the output file?

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)

Power BI Tables

I am using Power BI Desktop and want to create a table that stores the continents of the world. Can I just enter this in Power BI or do I need to find a source and import the data? Either of two correct answers is acceptable.

Answer: You can enter this by pressing "Enter Data" to create a table and enter data in the grid that appears, You can create a DAX expression in the Table Tools area of Power BI Desktop

Explanation: You can create a table in Power BI with the Get Data or in the Table Tools sections. The former gives you a grid where you can enter data. The latter allows you to use a DAX expression to return a table. Ref:

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
Uploading Transaction logs from a share folder - From our vendor we received a full back up copy of a database to create a copy of the database on our end. We also receive daily transaction logs to be applied to our copy of the database. I have restored the full back file (.bak) to our copy. Now I have to apply all […]
WMI PerfFormattedData and PerfRawData classes missing for one instance - Hello, I have a server with three instances: PROD, PROD17 and TEST. In WMI, I can find the Win32_PerfFormattedData_MSSQLPROD_* and Win32_PerfFormattedData_MSSQLTEST_* classes (idem with the PerfRawData classes), but not the PROD17 classes. Does anyone know how to create them? I've already tried mofcomp'ing all *.mof files in the instance directory, but that didn't help. Joost
Updating data - We have an account, which has update permissions. But when the account is try to use from the app, we are not seeing any updates happened on the tables even though the user has permissions.
SQL Server 2017 - Development
Need help to split string, and access the array - Hi, I've have this kind of string, dr strange~('2', '8', '6', '1', '13', '18')~('dcc23eb8-ea79-46ea-81e8-022c0752a31e', 'cfe164e3-4e1d-4292-9016-1aa5aef5bf07', '77481c15-1eda-4c0b-8c5c-168479b3c7cf', 'f39f33c7-09de-4bb4-9f07-ea93d04fdb47', '719707f8-8931-4e25-ac15-28c55284af1a', '733fe23b-d053-4d54-bb96-fe03573cf79d', '4ffb80d8-3c1a-4dcc-a3d6-f44865105123', 'c0b35951-5ecf-4fe2-85d4-580051caf1f5', '1dc4a64a-6859-4f98-be87-8e6507b4dc42', '4150771f-8dee-45b2-8661-c9890e94d2f1', '1850dd6e-2e03-49da-b0b4-e16ed24f371d')~('6', '2', '4', '5', '3', '1')~('3', '4', '2', '1', '6', '5')~0~900000000~30~100~2021-01-01 00:00:00~2022-05-03 00:00:00 The separator is ~ . It is tilde How to split and access the array[0] ? Please help
SQL Server 2016 - Administration
Login lacks connect endpoint permission error - Hello experts, I'm stumped by an error that a user is reporting, partly because the Windows Security event log seems to show audit success while the user is seeing a login failure. They are trying to connect to one of our SQL Server 2016 SP3 servers. They see this error: They see this error: Login […]
Windows Server 2019 OS not releasing SQL server file space - We are facing an issue with a SQL server 2016 server that is not releasing space to the OS. When running dbcc shrinkfile (OurDatabase_log,truncateonly) DbId FileId CurrentSize MinimumSize UsedPages EstimatedPages 12 2 1024 1024 1024 1024 DBCC LOGINFO RecoveryUnitId FileId FileSize StartOffset FSeqNo Status Parity CreateLSN 0 2 2031616 8192 31521 0 64 0 0 […]
SQL 2012 - General
Suspect_pages has 1 entry but Checkdb error is 0 - I have taken over SQL 2012 Server.   I found 1 entry in msdb.dbo.suspect_pages table with last_update_date being "2012-04-06 21:13:46.257".  The database this error is associated w/ is about 700GB.   Checkdb physcial_only is executed every day except 3rd Sunday of the month (Full Checkdb). No errors has been reported during these checks. I manually executed "DBCC […]
SQL Server 2019 - Administration
columnstore indexes with bad value PLE - Hello , I will proceed in the next few days to configure the columnstore indexes to replace the classic indexes what worries me in the subject is that I have not enough memory on the server I have the wrong value of the PLE counter and I heard additionally that columnstore indexes are rebuilt on […]
Resource Govenor for CPU usage - I need to set up a resource governor to restrain CPU use on one of my instances. But though I can find lots of articles telling me that I can do this, I can't find any that show code for the workload group. I've tried a number of things but because I'm writing queries for […]
RAM increase on server and sql instance -   I have increased server RAM from 8Gb to 40Gb and SQL max memory to 32Gb. However even after a month the total RAM usage by SQL server is 8.5Gb. some of the db have large data, any tips on investigating this further is appreciated. Thanks  
SQL Server 2019 - Development
most efficient way to compare columns across separate tables - Hi, I have no idea how to create this SQL query hence the reason I'm here. What would be the most efficient way to compare columns across separate tables? If the first rule was to match 5 columns, then the second rule is to match 4, third rule is to match 3 and so on. […]
is this possible with transact sql? - Hello! There's a table |Date|QueueName|Param| ---------------------- |0404|Queue0001|Q1P01| |0405|Queue0001|Q1P01| |0406|Queue0001|Q1P02| |0407|Queue0001|Q1P02| |0408|Queue0001|Q1P03| |0409|Queue0001|Q1P03| |0404|Queue0002|Q2P01| |0405|Queue0002|Q2P01| |0406|Queue0002|Q2P01| |0407|Queue0002|Q2P01| |0408|Queue0002|Q2P01| |0409|Queue0002|Q2P02| ...................... The aim is to have it transpose and create a script that will output the following table |QueueName|PrevP|Since|CurrP|Since| ----------------------------------- |Queue0001|Q1P02| 0406|Q1P03|0408 | |Queue0002|Q2P01| 0404|Q2P02|0409 | Would someone hint how this can be achieved?
DB size - Hi everyone I ran a script to see the size of DB. SELECT mdf.database_id, mdf.name, mdf.physical_name as data_file, ldf.physical_name as log_file, db_size_MB = CAST((mdf.size * 8.0)/1024 AS DECIMAL(8,2)), log_size_MB = CAST((ldf.size * 8.0 / 1024) AS DECIMAL(8,2)) FROM (SELECT * FROM sys.master_files WHERE type_desc = 'ROWS' ) mdf JOIN (SELECT * FROM sys.master_files WHERE type_desc […]
Amazon AWS and other cloud vendors
Proper way to setup EC2 with public SSH access - It's been a while since I setup EC2 instances for personal playing around. I just want to be able to connect from my personal Internet connection by ssh. I'm creating a new instance in the default VPC, with an allow rule for SSH from my own IP and with the public IP enabled. I'm wondering […]
General Cloud Computing Questions
Advice on How to Proceed? - So I decided to jump into cloud computing with 0 experience in anything computer related a year and a half ago. When I say 0 experience, I literally mean ZERO. I did not even really know what an IP address or even a server was. For some idiotic reason, I decided to get 3 basic […]
 

 

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

 

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