Copyright 2020 by McGraw-Hill Education. All rights reserved. Except as permitted under the United States Copyright Act of 1976, no part of this publication may be reproduced or distributed in any form or by any means, or stored in a database or retrieval system, without the prior written permission of the publisher.
ISBN: 978-1-26-045888-6
MHID: 1-26-045888-1
The material in this eBook also appears in the print version of this title: ISBN: 978-1-26-045887-9, MHID: 1-26-045887-3.
eBook conversion by codeMantra
Version 1.0
All trademarks are trademarks of their respective owners. Rather than put a trademark symbol after every occurrence of a trademarked name, we use names in an editorial fashion only, and to the benefit of the trademark owner, with no intention of infringement of the trademark. Where such designations appear in this book, they have been printed with initial caps.
McGraw-Hill Education eBooks are available at special quantity discounts to use as premiums and sales promotions or for use in corporate training programs. To contact a representative, please visit the Contact Us page at www.mhprofessional.com.
Information has been obtained by McGraw-Hill Education from sources believed to be reliable. However, because of the possibility of human or mechanical error by our sources, McGraw-Hill Education, or others, McGraw-Hill Education does not guarantee the accuracy, adequacy, or completeness of any information and is not responsible for any errors or omissions or the results obtained from the use of such information.
TERMS OF USE
This is a copyrighted work and McGraw-Hill Education and its licensors reserve all rights in and to the work. Use of this work is subject to these terms. Except as permitted under the Copyright Act of 1976 and the right to store and retrieve one copy of the work, you may not decompile, disassemble, reverse engineer, reproduce, modify, create derivative works based upon, transmit, distribute, disseminate, sell, publish or sublicense the work or any part of it without McGraw-Hill Educations prior consent. You may use the work for your own noncommercial and personal use; any other use of the work is strictly prohibited. Your right to use the work may be terminated if you fail to comply with these terms.
THE WORK IS PROVIDED AS IS. McGRAW-HILL EDUCATION AND ITS LICENSORS MAKE NO GUARANTEES OR WARRANTIES AS TO THE ACCURACY, ADEQUACY OR COMPLETENESS OF OR RESULTS TO BE OBTAINED FROM USING THE WORK, INCLUDING ANY INFORMATION THAT CAN BE ACCESSED THROUGH THE WORK VIA HYPERLINK OR OTHERWISE, AND EXPRESSLY DISCLAIM ANY WARRANTY, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. McGraw-Hill Education and its licensors do not warrant or guarantee that the functions contained in the work will meet your requirements or that its operation will be uninterrupted or error free. Neither McGraw-Hill Education nor its licensors shall be liable to you or anyone else for any inaccuracy, error or omission, regardless of cause, in the work or for any damages resulting therefrom. McGraw-Hill Education has no responsibility for the content of any information accessed through the work. Under no circumstances shall McGraw-Hill Education and/or its licensors be liable for any indirect, incidental, special, punitive, consequential or similar damages that result from the use of or inability to use the work, even if any of them has been advised of the possibility of such damages. This limitation of liability shall apply to any claim or cause whatsoever whether such claim or cause arises in contract, tort or otherwise.
About the Author
Duan Petkovi is a computer science professor at the Polytechnic in Rosenheim, Germany. He is the bestselling author of the six previous editions of this book and has written numerous articles for SQL Server Magazine.
About the Technical Editor
Todd Meister has been working in the IT industry for over 20 years. Hes been a technical editor on over 75 titles ranging from SQL Server to the .NET Framework. Besides technical editing books, he is the Assistant Vice President/Chief Enterprise Architect at Ball State University in Muncie, Indiana. He lives in central Indiana with his wife, Kimberly, and their five phenomenal children.
Acknowledgments
I would like to acknowledge the important contributions of my editor, Lisa McClain, my technical editor, Todd Meister, and my copy editor, Bill McManus.
Contents at a Glance
Introduction
Microsoft SQL Server is a database system that comprises many components, including the Database Engine, Analysis Services, Reporting Services, SQL Server Graph Databases, SQL Server Machine Learning Services, and several other components. The following are a few of the reasons SQL Server is the best choice for a broad spectrum of end users and database programmers building business applications:
SQL Server is certainly the best system for Windows operating systems, because of its tight integration (and low pricing). Because the number of installed Windows systems is enormous and still increasing, SQL Server is a widely used database system.
As of SQL Server 2017, Microsoft supports other operating systems as well: several Linux distributions, such as Ubuntu and Red Hat Linux, as well as macOS.
The Database Engine, as the relational database system component, is the easiest database system to use. In addition to the Database Engines well-known Windows-style user interface, Microsoft offers several different tools to help you create database objects, tune your database applications, and manage system administration tasks.
Generally, SQL Server isnt only a relational database system. It is a platform that not only manages structured, semistructured, unstructured, and graph data but also offers comprehensive, integrated operational and analysis software that enables organizations to reliably manage mission-critical information.
Goals of the Book
Microsoft SQL Server 2019: A Beginners Guide follows six previous editions that covered SQL Server 7, 2000, 2005, 2008, 2012, and 2016. SQL Server has evolved significantly since I wrote the first edition over 20 years ago, but my overarching goal has remained the same: to provide a comprehensive introduction to SQL Server that is friendly to beginners.
Generally, all SQL Server users who want to get a good understanding of this database system and to work successfully with it will find this book very helpful. If you are a new SQL Server user but understand SQL, read the section Differences Between SQL and Transact-SQL Syntax later in this introduction.
This book addresses users of different components of SQL Server. For this reason, it is divided into several parts: The first three parts are most useful to users who want to learn more about Microsofts relational database component called the Database Engine. The fourth part of the book is dedicated to Business Intelligence (BI) users who use Analysis Services and/or Reporting Services. The fifth part of the book provides insight for users who want to learn about SQL Server features beyond those specific to relational data, such as integration of the JSON format with the relational engine, support for temporal and spatial data, and support for graph databases as an integral part of SQL Server. The last part of the book describes SQL Server Machine Learning Services, which provides the integration of the R system and the Python programming language with SQL Server