| A community of more than 1,600,000 database professionals and growing |
| | Job Interviews: What is Normalization? This is part of a series that looks at interview questions that you might be asked. One of the cornerstones of a relational database is normalization. This is a database design technique that is used to decide how we might distribute data among tables and columns. If someone were to ask you "what is normalization" in your next job interview, what would you say? How do you answer this question? Depending on the position, and your experience, perhaps you'd talk about this in practical terms, with an example. Maybe you have a scenario you use to explain the concepts. I tend to lean towards an e-commerce type database, with orders, customers, and products. That's an easy concept for people to grasp. I can then give examples of how normalization might change the way we store data. Do you know there are various forms of normalization? We can talk about first, second, third, fourth, or other normal forms of the database. Perhaps you can explain these from memory? Maybe you know the academic definitions. Maybe you have your own description. I certainly think if the position may involve designing tables that you should be able to talk about the differences between these forms and determine what form a particular database is in. My answer would include quick explanations of how I would avoid repeating groups, columns not dependent on the PK, and how sometimes the third normal form starts to impact performance because of the number of joins required for simple queries. I would also be ready to expand on these topics, explaining what a PK is and how to choose one. This is a complex topic,and I doubt an interviewer would expect anyone to provide a thirty minute lecture, which wouldn't completely cover the topic. Instead, I would think that if an interviewer is interested in this topic, they will ask probing questions to determine if you understand the concepts. This means you can't just memorize the definition. You should ensure that if I have you a table, you could break it down into the entities for 1st, 2nd, and 3rd normal form. Perhaps you should read a few basic articles to get some understanding. Maybe you need to delve a little deeper into design and the anomalies that normalization attempts to mitigate. Prepping for an interview shouldn't be a cram session to learn more, but really a review of concepts you understand. Make sure you have some examples to explain your thoughts and practice a few of these questions with a friend by giving them an answer and listening to their feedback. Steve Jones from SQLServerCentral.comJoin the debate, and respond to today's editorial on the forums |
| The Voice of the DBA Podcast Listen to the MP3 Audio ( 3.6MB) podcast or subscribe to the feed at iTunes and Libsyn. 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 | | Database migrations inside Visual Studio Feeling the pain of managing and deploying database changes manually? Redgate ReadyRoll creates SQL migration scripts you can use to version control, build and release, and automate deployments. Try it free |
| | Watch SQL in the City Streamed 2017 The livestream recording for Redgate's December 2017 virtual event is now available. Technical sessions went into the latest Microsoft SQL Server releases, and covered topical issues such as DevOps, data compliance, protection & privacy. Watch the recording |
|
|
|
| | | David Poole from SQLServerCentral.com If a picture paints a thousand words then can GDPR regulation be represented in diagram form? Could doing so make it easier to comply with the regulation by making it easier to understand? More » |
| Over the past 20 years, the concept of database DevOps has always been around, but the ability to automate tasks hasn’t been as simple for the database as it has been for application development. Database DevOps tools have now emerged, however, and the benefits of including DevOps for the database are being realized by many organizations to achieve greater operational efficiency. More » |
| SQL Server Management Studio has been the default tool for working with SQL Server for over a decade. It’s not, however, compatible with any operating system outside of Microsoft Windows. SQL Operations Studio (SQLOPS), the open source program originally called ‘Project Carbon’, is now available for users of Linux and macOS as well as Windows. Robert Cain demonstrates the features of SQLOPS. More » |
| eitan 35333 from SQLServerCentral Blogs What are Orphaned Users “Orphaned Users” is a common issue in SQL Server where a Database User is no longer associated... More » |
| Brian Kelley from SQLServerCentral Blogs As a follow up to my tweet, I stand by my belief that DevOps does not make administrators obsolete. I... More » |
|
|
| | Today's Question (by Steve Jones): I run this code on my SQL Server 2016 instance: CREATE RULE dbo.DBASalaryRange AS @salary > 52000 AND @salary < 99000; Now I want to add this rule to the dbo.Employees table for the salary column. Which code should I use? |
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: Rules. 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 | T-SQL Querying (Developer Reference) Squeeze maximum performance and efficiency from every T-SQL query you write or tune. Four leading experts take an in-depth look at T-SQL’s internal architecture and offer advanced practical techniques for optimizing response time and resource usage. Get your copy from Amazon today. | | |
|
|
|
|
|
| Yesterday's Question of the Day |
| Yesterday's Question (by Steve Jones): I have a new class that I've created in R with this code (s4 version): > setClass( + "NFLTeam", + representation( + name = "character", + City = "character", + conference = "character", + division = "character" + ) + ) How do I create an instance of the class and assign it to the "denver.broncos" variable? Answer: denver.broncos = new("NFLTeam", name="Broncos", City="Denver", conference="AFC", division="West") Explanation: The new() function is used to create a new instance of a class. This is assigned to a variable with the <-. The various properties of the class are assigned after the type of class is given. For this question, the correct answer is: denver.broncos = new("NFLTeam", name="Broncos", City="Denver", conference="AFC", division="West") Ref: OO Essentials - click here » Discuss this question and answer on the forums |
|
|
| | Yusuf Kahveci from SQLServerCentral.com SQL Server Index Fragmentation analyze find script. Yusuf KAHVECI yusufkahveci@sqlturkiye.com www.sqlturkiye.com Thanks. 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 native client version 11.1 vs 11 - We upgrade our server from SQL server 2014 to 2017. I upgraded SSIS 2014 to 2017 by mainly change the connection... Error 17054 severity 16 state 1- SQL Server Automatically Restarts - In our environment, SQL server 2012 is automatically restarted, what will be issue??? Nothing related information is found in Event... Metldown and Spectre - Has anyone deployed any of the patches released for SQL 2016 and SQL 2017 to any of their environments. Is anyone... Divide column data into equal parts - I want to split one of the column's data into 8 equal parts. For eg. i have 73 rows currently... Migrating DBs off of sql 2014 to sql 2016 - All, I will be kicking off a migration project very soon wherein I will setup DB Mirroring in order to do... Deadlock help - Hi, Can you please help me to find what is causing dead lock here and possible fix for it? 2017-12-28 04:18:52.93 spid36s... store data changes(insert\update\delete) - Hi, Ii would like to store the information(EventDate EventDML LoginName DatabaseName TableName HostName IPAddress ProgramName ) in separate table if any data changes(insert\update\delete) happens in any table ... Ola's maintenance solution taking too long on VLDB's - All, I am looking into optimizing Ola's maintenance solution by tweaking around some parameters that is part of the stored proc.... Master database - I've got a server with 175 databases on it, all (theoretically) identical copies of each other from a metadata point... Row inserts for groups of rows (Totals for groups of like data). - I want to group data like all invoices from a supplier which is easy enough but when selecting multiple suppliers,... How to use HAVING with MAX on dates. - Hi, I need to do a report for sales reps showing the customers that haven;t ordered between a set of chosen... Query with Where clause + 3 OR clauses not working - after 40 minutes, none of the three conditions were returned in my results . . . and i had to stop the query... SQL to Excel : Using a SQL Table with Report Columns - This is a SQL to Excel question. We have a new SQL table with report columns and the position that... SELECT all negative values, that have a positive value - Hello, I need to identify in SQL server table all entries with a negative value, that have a positive value. How... Audit anyone - I'm wondering if some sort of tutorial exists explaining the basics of database auditing. Our users are complaining data in an... CASE statement slows down query drastically - If i comment out the case statement in this query, it takes less than a second. With the case statement,... How to add more partitions to existed table ? - I have a table that contains records of transactions with ID column is primary key I use partition follow ID column,... Agent job containing SSIS Package step runs forever but doesn't do anything. - I've seen a few reports of similar problems to this but none of the posted solutions seem to help with... 70-473 Anyone studying for this, or passed it? - Hello, I'm studying for this exam, just wondering if anyone else was? Regards, D Potential presentation idea: SQL Server for absolute beginners - So, I took today off from work to prepare and travel to SQL Saturday #517, and something occurred to me... |
|
| 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 |
|
|