200 likes | 539 Views
Querying Microsoft SQL Server 2012. Version 1.0. Author. MCAD MCSD MCPD Enterprise SQL MCTS MCT Software/Web Development Consultant Cryptography/Digital Signature Consultant SQL Server 2005/2008R2/2012 Consultant SharePoint 2007/2010/2013 Consultant AJAX Consultant
E N D
Querying Microsoft SQL Server 2012 Version 1.0
Author • MCAD • MCSD • MCPD Enterprise • SQL MCTS • MCT • Software/Web Development Consultant • Cryptography/Digital Signature Consultant • SQL Server 2005/2008R2/2012 Consultant • SharePoint 2007/2010/2013 Consultant • AJAX Consultant • Software Development Lead • Professional Scrum Master • Ahmad Adel Gad • mct@jemmail.com
Course Outline • Overview • Select Statement - Retrieve Data • Select Statement - Filtering Data • Working with NULL Values • Formatting Result Sets • System Functions • Combining and Limiting Result Sets • Grouping Data • Using Table Expressions Querying Microsoft SQL Server 2012 - Ahmad Adel
Course Outline • Windowing and Paging Data (Over Clause) • Querying SQL Server Metadata • Data Manipulation Language (DML) • Querying Full-Text Index Search • Distributed Queries • Implementing Error Handling (Handling Exceptions) • Implementing Transactions (TCL) Querying Microsoft SQL Server 2012 - Ahmad Adel
Overview • About SQL Language (T-SQL) • Introduction to Microsoft SQL Server 2012 Querying Microsoft SQL Server 2012 - Ahmad Adel
Select Statement - Retrieve Data • Fixed Values • Variables • Calculated Values • All Fields From Specific Table • Specific Fields From Specific Table • Concatenated Fields - Alias Name • Calculated Value On Specific Fields • Specific Columns From Table Alias Name • Value Returned From Function Querying Microsoft SQL Server 2012 - Ahmad Adel
Select Statement - Filtering Data • Comparison operators • Logical operators Querying Microsoft SQL Server 2012 - Ahmad Adel
Working with NULL Values • IS Null - Comparison • ANSI_NULLS Settings • ISNULL() Function • NullIF() Function • Coalesce()Function Querying Microsoft SQL Server 2012 - Ahmad Adel
Formatting Result Sets • Sorting Data • Eliminating Duplicate Rows Querying Microsoft SQL Server 2012 - Ahmad Adel
System Functions • Aggregate Functions • Scalar Functions • Converting Functions Querying Microsoft SQL Server 2012 - Ahmad Adel
Combining and Limiting Result Sets • Join • Inner/Where Clause • Outer(Full/Left/Right) • Cross • Self Join • Data Samples (TableSampleOperator) • Cube • Union/Except/Intersect • Apply (Cross/Outer) Querying Microsoft SQL Server 2012 - Ahmad Adel
Grouping Data • Group By • RollUP • Cube • Pivot - UnPivot Querying Microsoft SQL Server 2012 - Ahmad Adel
Using Table Expressions • Sub Queries • Derived Tables • Common Table Expressions (CTE) • Views • Table-Valued Functions Querying Microsoft SQL Server 2012 - Ahmad Adel
Windowing and Paging Data (Over Clause) • Paging Functions • Offset– Fetch • Row_Number • Over Clause • Ranking Functions • Analytic Functions • Aggregate Functions • NEXTVALUEFOR Querying Microsoft SQL Server 2012 - Ahmad Adel
Querying SQL Server Metadata • System Variable • System Stored Procedures • System Catalog Views • System Catalog Functions • Dynamic Management Views (DMV) • Dynamic Management Functions (DMF) Querying Microsoft SQL Server 2012 - Ahmad Adel
Data Manipulation Language (DML) • Insert • Update • Delete • Output Clause Querying Microsoft SQL Server 2012 - Ahmad Adel
Querying Full-Text Index Search • Contains • FreeText Querying Microsoft SQL Server 2012 - Ahmad Adel
Distributed Queries • OpenDataSource Function • OpenRowSet Function • Configure 'Ad Hoc Distributed Queries' Settings Querying Microsoft SQL Server 2012 - Ahmad Adel
Implementing Error Handling (Handling Exceptions) • @@Error Variable • Try … Catch • Throw Exceptions • RaiseError • Throw • System Error Information Functions • Error Severities Querying Microsoft SQL Server 2012 - Ahmad Adel
Implementing Transactions (TCL) • AutocommitTransactions • Implicit Transactions • Explicit Transactions • XACT_ABORT Setting • Implementing Transactions with Exception Handling • XACT_STATE() Function • Isolation Levels Querying Microsoft SQL Server 2012 - Ahmad Adel