SQLServerCentral - www.sqlservercentral.com

A community of more than 1,600,000 database professionals and growing

Featured Contents

Featured Script

The Voice of the DBA

Baby Steps to DevOps

I've been re-reading the book, Continuous Delivery, as part of the current San Diego Technology Immersion Group monthly meeting track. This book was the focus of the first meeting in May, and will continue for the next couple months. Continuous Delivery and the related, DevOps, are fascinating concepts, but mostly I find the discussions really interesting for me to see and hear how others view the DevOps, Continuous Integration (CI), and Continuous Deliver (CD), and where they apply in each person's organization.

One of the things I've noticed is that lots of people get overwhelmed with DevOps. They hear stories of how others are running an extremely efficient software development shop and think they couldn't implement CD in their organization. Or they think that CI/CD/DevOps is just a way of building software that's so far removed from their own experience. However, DevOps isn't really anything new or special. It's not even one thing, as there are many divergent views of what DevOps means. However, plenty of people have been applying and adhering to the various definitions of DevOps for decades, just viewing their process as efficient, effective, and empowered.

I use DevOps and CD somewhat interchangably, as they often proceed along the same path and each is a intertwined with the other. Note that going to a CD process doesn't mean that you release every day/hour/whatever. If means that you release when you want, which could still be every few months. It's just that you have a process set up to allow smooth process flow.

As I talk to people who are looking to build a DevOps process, and I hear about more and more of them all the time, one thing I stress is to take things slow. You won't build your DevOps process, whatever that looks like, this month. In fact, what you should expect to do is learn as you go, and whatever your vision of the process is today will change. You will learn, grow, change the way you do some things, and also change the way you implement new processes, even if you're copying how other companies have implemented their own system.

Most importantly, what I try to stress is to slowly move to CD (or DevOps). Look at the process you have now and just change one thing. Let's imagine that you:

  • manually track changes to the database in email
  • then build a change script manually
  • then have a DBA apply those changes
  • then let QA run tests with an application
  • then modify the script that goes to production

Leave that process as is. Let's implement one thing. Add some version control that will let you build a base for other changes. Your new process would be (changes in bold).

  • manually track changes to the database in email
  • then build a change script manually
  • store the change script in a VCS
  • then have a DBA apply those changes
  • then let QA run tests with an application
  • then modify the script that goes to production

Or change to this instead?

  • manually track changes to the database in email
  • then build a change script manually 
  • then have a DBA apply those changes 
  • then let QA run tests with an application 
  • then modify the script that goes to production
  • track all changes to production in an automated fashion (hopefully using a tool)

Over time, you can make another step. Maybe you use something like SQL Source Control or ReadyRoll to build change scripts and put them in a VCS. Or perhaps you build a process that takes the changes from the VCS and applies them to a test database without requiring the DBA to check things out and execute them. Both are valid ways to evolve your process. (Disclosure, I work for Redgate Software, maker of those products). I'm giving you a few suggestions here, but there are multiple ways, methods, and tools you could use.

And that's the key. You evolve your process, evolve your communication, learn to work together to accomplish goals. Not big goals, little goals. Add small items to your process as you realize they can be automated. Change communications in ways that help ensure everyone knows where to find code and how to deploy it. Or everyone knows how to set up environments (hopefully automated).

Slowly get better and better, and before long you'll find that you can make changes in smaller batches, and ensure those changes can be deployed at a rapid pace. Or maybe you'll have confidence to begin moving to a feature flag architecture so that you deploy changes well in advance of users being aware of them. Note, they're not perfect or the solution.

DevOps is about learning and growing. This is really the same basic principles that have driven Six Sigma and Kaizen and various other philosophies that recognize that we can do better over time. Make small steps, measure, learn, and improve.

Steve Jones from SQLServerCentral.com

Join the debate, and respond to today's editorial on the forums


The Voice of the DBA Podcast

Listen to the MP3 Audio ( 4.9MB) podcast or subscribe to the feed at iTunes and Mevio . feed

The Voice of the DBA podcast features music by Everyday Jones. No relation, but I stumbled on to them and really like the music. Support this great duo at www.everydayjones.com.

Everyday Jones

Follow Steve Jones on Twitter to find links and database related items and announcements.


ADVERTISEMENT
DLM Dashboard

Track schema changes for free

DLM Dashboard tracks SQL Server databases to show you exactly what schema changes have been made, by who, and when. You get a full history, with line-by-line differences, and a clear audit trail of your database moving from development to production. Download free tool.

ADVERTISEMENT

Have you got SQL fingers?

Get them here

SQL Finger Tips

Featured Contents

 

The COUNT Function in T-SQL

Igor Micev from SQLServerCentral.com

The COUNT function is among the most used functions in the T-SQL codes. Even though COUNT is easy to use, it should be used carefully because it could often not return the desired result. For the big tables, the counting of the rows could cause blocking as well as take some more time. More »


 

SQL Server 2014 Service Pack 2 is Available

Press Release from SQLServerCentral.com

SP2 for SQL Server 2014 is now out. Check out the build list. More »


 

Calculating MySQL Database, Table, and Column Sizes

Additional Articles from Database Journal

Rob Gravelle demonstrates a sure-fire way to calculate how much disk space your MySQL data entities are taking up. More »


 

From the SQLServerCentral Blogs - Automatic Seeding Very Large Databases in SQL Server 2016

jsterrett from SQLServerCentral Blogs

There are a lot of new features in SQL Server 2016. Availability Groups by itself got a lot of new... More »


 

From the SQLServerCentral Blogs - Introducing SQL Server Reporting Services

David Postlethwaite from SQLServerCentral Blogs

In an earlier post I introduced the SQL Server umbrella and briefly discussed a number of products that make up... More »

Question of the Day

Today's Question (by Steve Jones):

When virtualizing a SQL Server in a virtual machine, how are the components or a virtual system ordered from physical machine to the virtual machine? 

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: Virtualization.

We'd love to give you credit for your own question and answer.
To submit a QOTD, simply log in to the Contribution Center.

Yesterday's Question of the Day

Yesterday's Question (by Steve Jones):

I have three stored procedures that I want to run each time my SQL Server instance restarts. What should I do to ensure each of these three runs?

Answer: Mark each of the three procedures as a startup procedure with sp_procoption

Explanation:

The way to do this is mark each procedure as a startup procedure with sp_procoption. You could use one procedure to call the other three, but you do not have to do this.

Ref: sp_procoption - https://msdn.microsoft.com/en-us/library/ms181720.aspx


» Discuss this question and answer on the forums

Featured Script

Get earliest and latest date values in a database

Steve Armistead from SQLServerCentral.com

This executes in the current database. Be advised that the query selects the MIN and MAX datetime values for every table / column in the database, so it will probably run for a while in any database over a few GB in size. A 4 GB database with 86 datetime columns took 4 seconds on my SQL 2012 instance, and a 250 GB database with 1039 datetime columns took a little over 17 minutes. Ymmv (your mileage may vary). It depends on the number of rows in the tables, how many datetime columns in each table, and if there are any indexes that could help..... This is basically a "brute force" query, so prepare to give it time. Execute it on a non-production copy of your database if at all possible.

This comes in handy when evaluating previously unfamiliar databases for the first time, like in a new job or contract. 

Returns 2 recordsets - the 1st lists earliest and latest dates for each DATETIME or DATETIME2 column, the 2nd returns the min and max dates found across the entire database. 
As written, the query runs in SQL 2008 and later; switch the comment and "where" clause on line 21 to run in SQL 2005 and earlier.

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 2016 : SQL Server 2016 - Development and T-SQL

openjson - google books api - Morning everyone. I am trying to extract multiple authors from the google books api however when I try to return the...

how to find number of days between successive visists? - PatientId PatientNO Initials---- Patients Table 1 1 ABC 2 3 DEF 3 4 HIJ VisitId PatientID VisitNo VisitDate 1 1 1 12-Jan -2005 2 1 2 23-Jan-2005 3 1 3 28-Jan-2005 4 2 1 01-Feb-2005 5 2 2 08-Feb-2005 6 3 1 03-Feb-2005 7 3 2 08-Feb-2005 Produce a report showing the...


SQL Server 2014 : Administration - SQL Server 2014

BatchRequest\Sec Very Low - Hi Experts, The BatchRequest\Sec value for our OLTP system is showing 150 for the most critical time. I felt this as...

Backup Database is terminating abormally - The SQL 2014 is on version 12.0.2000.8 (64X). I have a stored procedure for daily full backup of every database (except...

Stored Procedure execution - Hi Team, In one of our prod server one stored procedure is taking long time to execute than normal execution. It is...


SQL Server 2014 : Development - SQL Server 2014

SSIS retrieving data from alwayson secondary - I have a number of SSIS packages (package deployment model) running on their own ETL server. I am trying to...

problem converting date on procedure. - hello, i have have a procedure that receives a date and a name and takes data from a table, but when...


SQL Server 2012 : SQL Server 2012 - T-SQL

Not a DBA admin - How do i optimize/tune my queries, check on missing index? - Hi, I appreciate this is quite a broad post. I do not have admin rights in our SQL 2008 sandpit. I have...

Convert Date List to Date Range - Hello, I have a table that a record gets inserted into every time a member subscribes or unsubscribes a list. Below is...

In SSISDB New folder not able to create. - While i'm creating a folder in Integration service catalog - SSISDB i'm getting an error as below, TITLE: Microsoft SQL Server Management...


SQL Server 2008 : SQL Server 2008 - General

Help creating a dynamic table of numbers - Hello all, I'm trying to dynamically create a table of days spanned for a aging report. I would like the end...


SQL Server 2008 : T-SQL (SS2K8)

Date Range overlaps - hi I have the sample data:Insert Into @Table (Id,Code, StartDate, EndDate, TimeDiff) [code="sql"]SELECT 1, 'DA6310', '2016-06-20 09:25:00.000', '2016-06-20 11:15:00.000', 110 Union...


Cloud Computing : General Cloud Computing Questions

how to Copy .bak file from S3 to RDS - Amazon Cloud - Greetings - I am trying to setup a DR solution.. I was able to copy .bak file to S3 bucket in...


Reporting Services : Reporting Services

where is this table populated then? must be loaded some how. - I have a report (.rdl file) - and a table called person and this table is using only in one stored...


Reporting Services : SSRS 2012

Blank rows after Page Break - Hi all, Have you ever come across adding conditional blank/empty rows after the page-break? Can it be done?


Data Warehousing : Integration Services

How can I use parameterized query (Select statement Where Col1= 'U') in OLEDB source of Data Flow task? - How can I use parameterized query (Select statement Where Col1= 'U') in OLEDB source of Data Flow task? Attached is a...

Need to export excel sheet with SPECIAL formats - Hi, I need to export an Excel sheet with special formats (mandatory) where SQL is the source. I have achieved it...


Data Warehousing : Analysis Services

Multidimensional vs Tabular - Hey, I'm completely new to SSAS and doing some research whilst working through tutorials to build my first analysis database. One thing...


SQL Server 2005 : SS2K5 Replication

Reinitializing Replication using t-sql - I am in need of reinitializing the transactional replication of a database after various upgrade scripts are ran against it....


SQL Server 7,2000 : T-SQL

BCP error -Unable to open BCP host data-file - SQLState = S1000, NativeError = 0 Error = [Microsoft][ODBC SQL Server Driver]Unable to open BCP host data-file NULL   I am getitng the above error when i...

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 ©2015 Redgate Software Ltd, Newnham House, Cambridge Business Park, Cambridge, CB4 0WZ, United Kingdom. All rights reserved.
Contact: webmaster@sqlservercentral.com