Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY...
-
Upload
ariana-reid -
Category
Documents
-
view
216 -
download
3
Transcript of Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY...
![Page 1: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/1.jpg)
blackmarble
the strategic IT asset for your organisation
MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO
TEAM SYSTEM
Richard FennellEngineering Director
SQLBits IV 28th March 2009
![Page 2: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/2.jpg)
blackmarble
Agenda
• Why do we need DB Pro.?• What is Visual Studio Team System• DB Pro. Features
– Project Life-cycle– Testing– Deployment– Power Tools
• The Future
![Page 3: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/3.jpg)
blackmarble
Pain points in DB development
• What is the ‘correct DB schema’?• How do we version control it?• How do I know the impact of a change?• How do we publish a DB?• Where do we get test data from?• How do we test it anyway?
• There has been no ‘Microsoft standard’ way to manage the DB – until now
![Page 4: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/4.jpg)
ExcelExcel
ProjectProject
Operations, QA Operations, QA and Help Deskand Help Desk Non-Microsoft Non-Microsoft
DeveloperDeveloper
Team System Team System Web AccessWeb Access
Visual Studio Team SystemApplication Life Cycle Management (ALM) Solution
![Page 5: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/5.jpg)
blackmarble
Visual Studio for Database Professionals
• Incorporates the Database Professional into the software development lifecycle
• Provides a foundation for change management and process integration
• Exposes database schema as individual script files
• Provides a set of essential tools– Version Control via Visual Studio supported providers– Rename Refactoring– Schema Comparison Tools– Data Comparison Tools
![Page 6: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/6.jpg)
blackmarble
Visual Studio for Database Professionals
• Was known as ‘DataDude’ in beta phase
• Released in 2006
• Release VS 2008 was really more of a service pack than a major release.
• VS 2008 GDR Released November 2008
![Page 7: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/7.jpg)
blackmarble
Visual Studio Team System 2008Database Edition GDR
• Builds on top of Visual Studio 2008 SP1• Adds support for SQL Server 2008• Introduces a new product architecture
– Database Schema Provider model– Separation of Build & Deploy– Public Extensibility
• Incorporates functionality previouslyshipped in the Power Tools– T-SQL Static Code Analysis– Dependency Viewer
• Many product enhancements and improvements
![Page 8: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/8.jpg)
Database Project Ecosystem
DatabaseRefactoring
DatabaseUnit Testing
Data Generation
T-SQL Static Code
Analysis
Schema Compare
DataCompare
3rd PartyDesigners
3rd PartyTools
SQL Server2008 DSP
ParserScriptDOMInterpreterReverse EngineerDeploy
SQL Server2005 DSP
ParserScriptDOMInterpreterReverse EngineerDeploy
SQL Server2000 DSP
ParserScriptDOMInterpreterReverse EngineerDeploy
3rd PartyDSP
ParserScriptDOMInterpreterReverse EngineerDeploy
DSPExtensions
DSPExtensions
DSPExtensions
DSPExtensions
DSPExtensions
DS
P E
xtensio
ns
DSPExtensions
Database Model API
Database Eco Project System
Solution ExplorerSchema ViewDependency
ViewerEditor
Project Features
![Page 9: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/9.jpg)
blackmarble
Team Foundation Server Integration
• As a member of the Visual Studio Team System family, DBPro is integrated with all of the team features
• TFS provides– Team project with prescriptive guidance– Version control management– Work Item tracking– Team Build integration
![Page 10: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/10.jpg)
blackmarble
Database Edition Power Tools
• Power Tools 2008 added additional features that didn’t make the product release cycle– Dependency Viewer – New Refactorings– Data Generation Wizard– MSBuild Tasks – T-SQL Static Code Analysis – Schema Manager API
• At present no GDR Power tools released
![Page 11: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/11.jpg)
Writes Tests
Writes DB Code
Refactors
Runs Tests
Checks In
Works with other developers to integrate
Reviews Changes
Compares Updates to Production
Builds Deploy Package
Deploys to Production
Creates New DB Project
Reverse Engineers DB to Project
Creates Data Generation Plan
DB DeveloperDB Administrator
Manage Develop Deploy
Roles in a DB Project
DB Administrator
![Page 12: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/12.jpg)
Creating the DB Project
DatabaseDatabaseProjectProject Import schemaImport schema
Check in to
Check in to
Source
Source
Control
Control
ProductionProductionDatabaseDatabase
StagingStagingDatabaseDatabase
Create a ProjectCreate a Project
DBADBA
DBProDBPro
TFSTFSServerServer
![Page 13: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/13.jpg)
DBProDBPro
TFSTFSServerServer
DBADBA
Isolated Iterative Development• Sync Sync • Check-outCheck-out• Edit/RefactorEdit/Refactor• TestTest• Check-inCheck-in• Work is being drivenWork is being driven
and tracked viaand tracked viawork itemswork items
• Other team members can Other team members can pick up changespick up changes
TFS Shelving TFS Shelving allows DBAallows DBAto provide guidanceto provide guidanceand evaluate workand evaluate work
ProductionDatabase
StagingDatabase
SandboxDatabase
SandboxDatabase
SandboxDatabase
![Page 14: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/14.jpg)
DBProDBPro
TFSTFSServerServer
Automated Build & Testing
Build ServerBuild Server
Test Test
DBADBA
ProductionDatabase
StagingDatabase
Get LatestGet Latest
TestTestEnvironmentEnvironment
Reports
![Page 15: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/15.jpg)
Deploy the Project
DatabaseDatabaseProjectProject
Sync from
S
ync from
Label Label
SQLSQLDeploy Deploy ScriptScriptBuildBuild
DeployDeploy
Refine deploy Refine deploy scriptscript
VerifyVerify
DBProDBPro
TFSTFSServerServer
DBADBA
ProductionDatabase
StagingDatabase
PublishPublish
![Page 16: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/16.jpg)
blackmarble
Schema Model
Schema CompilationSource
Database
.dbschemafile
Project System
DDL Scripts(artifacts)
Reverse engineer schemainto DDL artifacts
Compose model representationfrom source code fragments
Build
Interpret,
Analyze and
Validate
Schema Model
Interpret,
Analyze and
Validate
Schema Model
![Page 17: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/17.jpg)
Schema Deployment
Schema Model
TargetDatabase
Schema Model
.dbschemafile
Deployment Engine
Model Diff
Incremental Target UpdateAdditional schema artifacts
.SQL
…
Plan Executors
![Page 18: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/18.jpg)
blackmarble
the strategic IT asset for your organisation
demodemo
DB Life CycleDB Life Cycle
![Page 19: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/19.jpg)
blackmarble
Data Generation
• Shipped with the product– Data-bound, Regular Expression, Random Number
• Available as a Power Tool– File-bound and a Wizard tools to ease the process
• Codeplex – DbProGenerators– Lorem Ipsum, sparse columns, XML bound, Word
bound and web search bound
• Plus what you write yourself.....
![Page 20: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/20.jpg)
blackmarble
the strategic IT asset for your organisation
demodemo
Data GenerationData Generation
![Page 21: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/21.jpg)
blackmarble
Testing in DB Pro
• Firstly remember that can test any CLR code before loading it into SQL Server
• DBPro adds database tests that can be used to test any stored procedure, function, trigger or DB object
• A single test project can contain a variety of test types
• Can be used to auto generate test stubs
![Page 22: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/22.jpg)
blackmarble
the strategic IT asset for your organisation
demodemo
Automated TestingAutomated Testing
![Page 23: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/23.jpg)
blackmarble
Is DB Testing Valid?
• You have to ask how useful it is to test at the raw data layer?
• Usually more effective to test the DB via the data access layer or as part of integration testing
![Page 24: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/24.jpg)
blackmarble
MSBuild
• All the key DB tasks can be scripted
• Database operations can become part of a scheduled build
• However this can all get a bit complex and DBPro MSBuild tasks are a bit idiosyncratic.
• Check the web for examples
![Page 25: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/25.jpg)
blackmarble
The Future
• Developer & Database Team Editions merged
• Database Schema Providers– Publicly extensible in Visual Studio 2010
– Quest Software announced that they will offer a Database Schema Provider (DSP) for Oracle
– Partnership with IBM provides DB2 support
• Contextual Project Feature Extensibility– Publicly extensible in Visual Studio 2010
![Page 26: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/26.jpg)
blackmarble
Summary
• Visual Studio Team Edition for Database Professionals make SQL development part of the project mainstream.
• Team System coupled with integrated version control helps to mitigate risks associated with DB schema change
• Build integration provides for quality tracking and improvement
• Process reduces last minute problems and the need to rollback changes out of production
![Page 27: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/27.jpg)
blackmarble
Good VSTS Blogs
• Gert Drapers (was Architect/Development Manager Visual Studio Team Edition for DB Professionals, but moved to new team Mar 09)– http://blogs.msdn.com/gertd
• VSTS DB Team Blog (replaces Gert’s blog)– http://blogs.msdn.com/vstsdb/
• Brian Harry (Product Unit Manager for Team Foundation Server)– http://blogs.msdn.com/bharry
![Page 28: Black marble the strategic IT asset for your organisation MAKING THE SQL DEVELOPER ONE OF THE FAMILY WITH VISUAL STUDIO TEAM SYSTEM Richard Fennell Engineering.](https://reader034.fdocuments.us/reader034/viewer/2022042814/55142e14550346dd488b5e5b/html5/thumbnails/28.jpg)
blackmarble
For Further Information
• My random thoughts ‘But it works on my PC!’ http://blogs.blackmarble.co.uk/blogs/rfennell
• You can also get in touch via: Email – [email protected]
WebSite – www.blackmarble.co.uk