did-you-know? rent-now

Amazon no longer offers textbook rentals. We do!

did-you-know? rent-now

Amazon no longer offers textbook rentals. We do!

We're the #1 textbook rental company. Let us show you why.

9781590597293

Expert SQL Server 2005 Development

by
  • ISBN13:

    9781590597293

  • ISBN10:

    159059729X

  • Format: Paperback
  • Copyright: 2007-05-21
  • Publisher: Springer-Verlag New York Inc
  • Purchase Benefits
  • Free Shipping Icon Free Shipping On Orders Over $35!
    Your order must be $35 or more to qualify for free economy shipping. Bulk sales, PO's, Marketplace items, eBooks and apparel do not qualify for this offer.
  • eCampus.com Logo Get Rewarded for Ordering Your Textbooks! Enroll Now
List Price: $49.99 Save up to $33.11
  • Buy New
    $48.49
    Add to Cart Free Shipping Icon Free Shipping

    USUALLY SHIPS IN 2-3 BUSINESS DAYS

Supplemental Materials

What is included with this book?

Summary

While building on the skills you already have, Expert SQL Server 2005 Development will help you become an even better developer by focusing on best practices and demonstrating how to design highperformance, maintainable database applications.This book starts by reintroducing the database as a integral part of the software development ecosystem. Yours"ll learn how to think about SQL Server development as you would any other software development. For example, there's no reason you canrs"t architect and test database routines just as you would architect and test application code. And nothing should stop you from implementing the types of exception handling and security rules that are considered so important in other tiers, even if they are usually ignored in the database.Yours"ll learn how to apply development methodologies like these to produce highquality encryption and SQLCLR solutions. Furthermore, yours"ll discover how to exploit a variety of tools that SQL Server offers in order to properly use dynamic SQL and to improve concurrency in your applications. Finally, yours"ll become well versed in implementing spatial and temporal database designs, as well as approaching graph and hierarchy problems.

Table of Contents

Forewordp. xiii
About the Authorsp. xv
About the Technical Reviewerp. xvii
Acknowledgmentsp. xix
Introductionp. xxi
Software Development Methodologies for the Database Worldp. 1
Architecture Revisitedp. 2
Coupling, Cohesion, and Encapsulationp. 2
Interfacesp. 5
The Central Problem: Integrating Databases and Object-Oriented Systemsp. 8
Where Should the Logic Go?p. 8
The Object-Relational Impedance Mismatchp. 12
ORM: A Solution That Creates Many Problemsp. 17
Introducing the Database-as-API Mindsetp. 18
The Great Balancing Actp. 19
Testabilityp. 19
Maintainabilityp. 19
Securityp. 20
Performancep. 21
Creeping Featurismp. 21
Summaryp. 22
Testing Database Routinesp. 23
Introduction to Black Box and White Box Testingp. 23
Unit and Functional Testingp. 24
Unit Testing Frameworksp. 26
The Importance of Regression Testingp. 29
Guidelines for Implementing Database Testing Processes and Proceduresp. 30
Why Is Testing Important?p. 30
What Kind of Testing Is Important?p. 31
How Many Tests Are Weeded?p. 31
Will Management Buy In?p. 32
Performance Testing and Profiling Database Systemsp. 33
Capturing Baseline Metricsp. 33
Profiling Using Traces and SQL Server Profilerp. 34
Evaluating Performance Countersp. 36
Big-Picture Analysisp. 37
Granular Analysisp. 38
Fixing Problems: Is Focusing on the Obvious Issues Enough?p. 40
Introducing the SQLQueryStress Performance Testing Toolp. 40
Summaryp. 45
Errors and Exceptionsp. 47
Exceptions vs. Errorsp. 47
How Exceptions Work in SQL Serverp. 48
Statement-Level Exceptionsp. 48
Batch-Level Exceptionsp. 49
Parsing and Scope-Resolution Exceptionsp. 50
Connection and Server-Level Exceptionsp. 52
The Xact_Abort Settingp. 52
Dissecting an Error Messagep. 53
SQL Server's Raiserror Functionp. 56
Monitoring Exception Events with Tracesp. 60
Exception Handlingp. 60
Why Handle Exceptions in T-SQL?p. 60
Exception "Handling" Using @@Errorp. 61
SQL Server's Try/Catch Syntaxp. 62
Transactions and Exceptionsp. 68
The Myths of Transaction Abortionp. 68
Xact_Abort: Turning Myth into (Semi-)Realityp. 69
Try/Catch and Doomed Transactionsp. 71
Summaryp. 72
Privilege and Authorizationp. 73
The Principle of Least Privilegep. 74
Creating Proxies in SQL Serverp. 74
Data Security in Layers: The Onion Modelp. 75
Data Organization Using Schemasp. 76
Basic Impersonation Using Execute Asp. 79
Ownership Chainingp. 81
Privilege Escalation Without Ownership Chainsp. 83
Stored Procedures and Execute Asp. 83
Stored Procedure Signing Using Certificatesp. 85
Summaryp. 89
Encryptionp. 91
What to Protectp. 92
Encryption Terminology: What You Need to Knowp. 93
SQL Server 2005 Encryption Key Hierarchyp. 94
Service Master Keyp. 95
Database Master Keyp. 95
SQL Server 2005 Data Protectionp. 97
HashBytes()p. 97
Asymmetric Key and Certificate Encryptionp. 98
Symmetric Key Encryptionp. 101
EncryptByPassphrasep. 108
Securing Data from the DBAp. 109
Architecting for Performancep. 111
Setting Up the Solution and Defining the Problemp. 112
Searching Encrypted Datap. 116
Summaryp. 131
SQLCLR: Architecture and Design Considerationsp. 133
Bridging the SQL/CLR Gap: the SqlTypes Libraryp. 134
Wrapping Code to Promote Cross-Tier Reusep. 135
A Simple Example: E-Mail Address Format Validationp. 135
SQLCLR Security and Reliability Featuresp. 137
The Quest for Code Safetyp. 140
Selective Privilege Escalation via Assembly Referencesp. 141
Granting Cross-Assembly Privilegesp. 148
Enhancing Service Broker Scale-Out with SQLCLRp. 151
Extending User-Defined Aggregatesp. 162
Summaryp. 167
Dynamic T-SQLp. 169
Dynamic T-SQL vs. Ad Hoc T-SQLp. 169
The Stored Procedure vs. Ad Hoc SQL Debatep. 170
Why Go Dynamic?p. 171
Compilation and Parameterizationp. 172
Auto-Parameterizationp. 174
Application-Level Parameterizationp. 175
Performance Implications of Parameterization and Cachingp. 177
Supporting Optional Parametersp. 180
Optional Parameters via Static T-SQLp. 180
Going Dynamic: Using Executep. 186
SQL Injectionp. 192
sp_executesql: A Better Executep. 195
Dynamic SQL Security Considerationsp. 204
Permissions to Referenced Objectsp. 204
Interface Rulesp. 205
Summaryp. 207
Designing Systems for Application Concurrencyp. 209
The Business Side: What Should Happen When Processes Collide?p. 210
A Brief Overview of SQL Server Isolation Levelsp. 211
Concurrency Control and SQL Server's Native Isolation Levelsp. 216
Preparing for the Worst: Pessimistic Concurrencyp. 217
Enforcing Pessimistic Locks at Write Timep. 222
Application Locks: Generalizing Pessimistic Concurrencyp. 224
Hoping for the Best: Optimistic Concurrencyp. 234
Embracing Conflict: Multivalue Concurrencyp. 239
Extending Scalability Through Queuingp. 243
Summaryp. 249
Working with Spatial Datap. 251
Representing Geospatial Data by Latitude and Longitudep. 251
Setting Up Sample Datap. 253
Calculating the Distance Between Two Pointsp. 254
Moving from Point to Pointp. 259
Searching the Neighborhoodp. 263
The Bounding Boxp. 269
Finding the Nearest Neighborp. 281
The Dynamic Bounding Boxp. 284
Conclusionp. 293
Representing Geospatial Data by Using the Hierarchical Triangular Meshp. 294
A Simplified Description of HTMp. 294
Implementing the HtmIDp. 298
Functions in the Spatial Databasep. 300
Conclusionp. 311
Other Types of Spatial Datap. 312
Three-Dimensional Datap. 312
Astronomical Datap. 312
Virtual Spacep. 312
Representing Regions As Polygonsp. 313
Summaryp. 313
Working with Temporal Datap. 315
Representing More Than Just Timep. 315
SQL Server's Date/Time Data Typesp. 316
Input Date Formatsp. 316
Output Date Formattingp. 318
Efficiently Querying Date/Time Columnsp. 320
Date/Time Calculationsp. 323
Defining Periods Using Calendar Tablesp. 329
Designing and Querying Temporal Data Storesp. 340
Dealing with Time Zonesp. 341
Working with Intervalsp. 348
Modeling Durationsp. 368
Managing Bitemporal Datap. 370
Summaryp. 373
Trees, Hierarchies, and Graphsp. 375
Terminology: Everything Is a Graphp. 375
The Basics: Adjacency Lists and Graphsp. 377
Constraining the Edgesp. 378
Basic Graph Queries: Who Am I Connected To?p. 380
Traversing the Graphp. 381
Adjacency List Hierarchiesp. 391
Querying Adjacency List Hierarchies: The Basicsp. 392
Finding Direct Descendantsp. 393
Traversing down the Hierarchyp. 395
Traversing up the Hierarchyp. 404
Inserting New Nodes and Relocating Subtreesp. 405
Deleting Existing Nodesp. 406
Constraining the Hierarchyp. 407
Persisting Materialized Pathsp. 409
Finding Subordinatesp. 411
Navigating up the Hierarchyp. 412
Optimizing the Materialized Path Solutionp. 413
Inserting Nodesp. 418
Relocating Subtreesp. 419
Deleting Nodesp. 422
Constraining the Hierarchyp. 422
Nested Sets Modelp. 422
Finding Subordinatesp. 426
Navigating up the Hierarchyp. 428
Inserting Nodesp. 428
Relocating Subtreesp. 430
Deleting Nodesp. 435
Constraining the Hierarchyp. 436
Summaryp. 437
Indexp. 439
Table of Contents provided by Ingram. All Rights Reserved.

Supplemental Materials

What is included with this book?

The New copy of this book will include any supplemental materials advertised. Please check the title of the book to determine if it should include any access cards, study guides, lab manuals, CDs, etc.

The Used, Rental and eBook copies of this book are not guaranteed to include any supplemental materials. Typically, only the book itself is included. This is true even if the title states it includes any access cards, study guides, lab manuals, CDs, etc.

Rewards Program